aboutsummaryrefslogtreecommitdiffstats
path: root/mail/dbmail21/files/patch-2.1.7_004
blob: 6fbd421ffe2406fb68b0b034b4fcb2cdf1e30c3d (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
Index: debug.c
===================================================================
--- debug.c (revision 2214)
+++ debug.c (revision 2215)
@@ -103,6 +103,7 @@
        fprintf(stderr, "%s %s", trace_to_text(level), message);
        if (message[l] != '\n')
            fprintf(stderr, "\n");
+       fflush(stderr);
    }
 
    if (level <= TRACE_SYSLOG) {
Index: modules/sortsieve.c
===================================================================
--- modules/sortsieve.c (revision 2214)
+++ modules/sortsieve.c (revision 2215)
@@ -187,7 +187,7 @@
    extern const char * imap_flag_desc[];
    const char * const * flags;
    const char * mailbox;
-   int msgflags[IMAP_NFLAGS];
+   int *msgflags = NULL;
 
    mailbox = sieve2_getvalue_string(s, "mailbox");
    flags = sieve2_getvalue_stringlist(s, "imapflags"); // TODO
@@ -198,9 +198,9 @@
    }
 
    /* If there were any imapflags, set them. */
-   memset(&msgflags, 0, IMAP_NFLAGS * sizeof(int));
    if (flags) {
        int i, j;
+       msgflags = g_new0(int, IMAP_NFLASGS);
 
        for (i = 0; flags[i]; i++) { // Loop through all script/user-specified flags.
            for (j = 0; imap_flag_desc[j]; i++) { // Find the ones we support.
Index: ChangeLog
===================================================================
--- ChangeLog   (revision 2214)
+++ ChangeLog   (revision 2215)
@@ -1,3 +1,11 @@
+2006-07-27  Aaron Stone  <aaron@serendipity.cx>
+
+   * debug.c:
+   Added fflush after fprintf (closes bug #388).
+   * modules/sortsieve.c:
+   Make sure that the msgflags pointer is NULL if there are no special
+   flags (closes bug #383).
+
 2006-07-26  Paul J Stevens <paul@nfg.nl>
 
    * debian/control, modules/sortsieve.c: