diff options
author | Not Zed <NotZed@Ximian.com> | 2001-01-29 09:13:17 +0000 |
---|---|---|
committer | Michael Zucci <zucchi@src.gnome.org> | 2001-01-29 09:13:17 +0000 |
commit | 0eb3633d247998075771794baf844fb775359969 (patch) | |
tree | 715b71d746bbdb73d6d7f2cf8ef4a5cb09f539e4 | |
parent | fc6d47579b895e2d371460ea5c24e9d7ce8d43e2 (diff) | |
download | evolution-data-server-0eb3633d247998075771794baf844fb775359969.tar.gz |
Include the terminating NUL in the calculated string length. This hit
2001-01-29 Not Zed <NotZed@Ximian.com>
* providers/imap/camel-imap-command.c
(imap_command_strdup_vprintf): Include the terminating NUL in the
calculated string length. This hit memcheck.
-rw-r--r-- | camel/ChangeLog | 6 | ||||
-rw-r--r-- | camel/providers/imap/camel-imap-command.c | 2 |
2 files changed, 7 insertions, 1 deletions
diff --git a/camel/ChangeLog b/camel/ChangeLog index 2f5dbaf1e..fcaa28014 100644 --- a/camel/ChangeLog +++ b/camel/ChangeLog @@ -1,3 +1,9 @@ +2001-01-29 Not Zed <NotZed@Ximian.com> + + * providers/imap/camel-imap-command.c + (imap_command_strdup_vprintf): Include the terminating NUL in the + calculated string length. This hit memcheck. + 2001-01-25 Not Zed <NotZed@Ximian.com> * tests/folder/test3.c: Changed the subject search to handle case diff --git a/camel/providers/imap/camel-imap-command.c b/camel/providers/imap/camel-imap-command.c index db8cdd29d..8a713cde8 100644 --- a/camel/providers/imap/camel-imap-command.c +++ b/camel/providers/imap/camel-imap-command.c @@ -530,7 +530,7 @@ imap_command_strdup_vprintf (CamelImapStore *store, const char *fmt, } /* Now write out the string */ - op = out = g_malloc (len); + op = out = g_malloc (len + 1); p = start = fmt; i = 0; while (*p) { |