]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
minor fix
authorTimo Sirainen <tss@iki.fi>
Mon, 28 Apr 2003 16:31:59 +0000 (19:31 +0300)
committerTimo Sirainen <tss@iki.fi>
Mon, 28 Apr 2003 16:31:59 +0000 (19:31 +0300)
--HG--
branch : HEAD

src/imap/commands-util.c

index c1c04949bf1981e6d029f759cab75f30b87bfe64..5f487f378d02a569c087c75b2f040ebe6814fbb6 100644 (file)
@@ -296,6 +296,12 @@ void client_save_custom_flags(struct mailbox_custom_flags *dest,
 
        p_clear(dest->pool);
 
+       if (custom_flags_count == 0) {
+               dest->custom_flags = NULL;
+               dest->custom_flags_count = 0;
+               return;
+       }
+
        dest->custom_flags =
                p_new(dest->pool, char *, custom_flags_count);
        dest->custom_flags_count = custom_flags_count;