Svace issue fixes 10/199910/1 accepted/tizen_5.5_unified_mobile_hotfix tizen_5.5_mobile_hotfix tizen_5.5_tv accepted/tizen/5.5/unified/20191031.013354 accepted/tizen/5.5/unified/mobile/hotfix/20201027.071955 accepted/tizen/unified/20190218.064030 submit/tizen/20190216.112009 submit/tizen_5.5/20191031.000008 submit/tizen_5.5_mobile_hotfix/20201026.185108 tizen_5.5.m2_release
authorkamaljeet <kamal.jc@samsung.com>
Fri, 15 Feb 2019 10:45:22 +0000 (16:15 +0530)
committerkamaljeet <kamal.jc@samsung.com>
Fri, 15 Feb 2019 10:45:22 +0000 (16:15 +0530)
Change-Id: I3ac57b4ec15c1dfa0d3093877aa44780ab9ccb14
Signed-off-by: kamaljeet <kamal.jc@samsung.com>
imap-2007e/c-client/mail.c

index 9020b68..080877c 100755 (executable)
@@ -4636,6 +4636,7 @@ SORTCACHE **mail_sort_loadcache (MAILSTREAM *stream,SORTPGM *pgm)
              case 'T':
                if (v = strchr (v,':')) {
                  memmove (x,v+1,strlen (v+1));
+                 x[strlen (v)] = '\0';
                  break;
                }
              default:          /* tie off extraneous text */
@@ -4665,6 +4666,7 @@ SORTCACHE **mail_sort_loadcache (MAILSTREAM *stream,SORTPGM *pgm)
              case ' ':         /* erase continuation newlines */
              case '\t':
                memmove (x,v,strlen (v));
+               x[strlen (v)-1] = '\0';
                break;
              default:          /* tie off extraneous text */
                *x = x[1] = '\0';
@@ -5606,6 +5608,7 @@ long mail_sequence (MAILSTREAM *stream,unsigned char *sequence)
       break;
     case ',':                  /* single message */
       ++sequence;              /* skip the delimiter, fall into end case */
+       break;
     case '\0':                 /* end of sequence, mark this message */
       mail_elt (stream,i)->sequence = T;
       break;