fixed error in imap protocol and in imap things
authorHoà Viêt Dinh <dinh.viet.hoa@free.fr>
Fri, 26 Jul 2002 22:40:11 +0000 (22:40 +0000)
committerHoà Viêt Dinh <dinh.viet.hoa@free.fr>
Fri, 26 Jul 2002 22:40:11 +0000 (22:40 +0000)
ChangeLog.claws
configure.in
src/imap.c

index 34952ea..2fedb67 100644 (file)
@@ -1,3 +1,11 @@
+2002-07-26 [hoa]       0.8.0claws20
+
+       * src/folder.c
+               Fixed a condition in folder_item_destroy()
+
+       * src/imap.c
+               Fixed an error in IMAP protocol
+
 2002-07-26 [alfons]    0.8.0claws19
 
        * src/folder.c
index fe86458..1e9e176 100644 (file)
@@ -8,7 +8,7 @@ MINOR_VERSION=8
 MICRO_VERSION=0
 INTERFACE_AGE=0
 BINARY_AGE=0
-EXTRA_VERSION=claws19
+EXTRA_VERSION=claws20
 VERSION=$MAJOR_VERSION.$MINOR_VERSION.$MICRO_VERSION$EXTRA_VERSION
 
 dnl set $target
index 477250c..dded5c6 100644 (file)
@@ -3206,9 +3206,16 @@ MsgInfo *imap_fetch_msginfo(Folder *_folder, FolderItem *item, gint num)
        g_string_assign(str, tmp);
        g_free(tmp);
 
-       msginfo = imap_parse_envelope(SESSION(session)->sock, item, str);
-       if (!msginfo) {
-               log_warning(_("can't parse envelope: %s\n"), str->str);
+       if (str->str[0] == '*') {
+               msginfo = imap_parse_envelope(SESSION(session)->sock,
+                                             item, str);
+               if (!msginfo) {
+                       log_warning(_("can't parse envelope: %s\n"), str->str);
+               }
+       }
+       else {
+               g_string_free(str, TRUE);
+               return NULL;
        }
 
        tmp = NULL;
@@ -3216,7 +3223,7 @@ MsgInfo *imap_fetch_msginfo(Folder *_folder, FolderItem *item, gint num)
                g_free(tmp);
                tmp = sock_getline(SESSION(session)->sock);
        } while (!(tmp == NULL || tmp[0] != '*' || tmp[1] != ' '));
-       
+
        msginfo->folder = item;
 
        g_string_free(str, TRUE);