projects
/
claws.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e72d26e
)
One more leak (introduced in previous commit)
author
Colin Leroy
<colin@colino.net>
Fri, 13 Nov 2015 12:47:48 +0000
(13:47 +0100)
committer
Colin Leroy
<colin@colino.net>
Fri, 13 Nov 2015 12:47:48 +0000
(13:47 +0100)
src/plugins/mailmbox/mmapstring.c
patch
|
blob
|
history
diff --git
a/src/plugins/mailmbox/mmapstring.c
b/src/plugins/mailmbox/mmapstring.c
index 2a70e5ebc11c47faa14b495be532ed293b1db1e7..535e04bcea2166b0b9c63753a1df8d3579852bd1 100644
(file)
--- a/
src/plugins/mailmbox/mmapstring.c
+++ b/
src/plugins/mailmbox/mmapstring.c
@@
-300,11
+300,15
@@
mmap_string_sized_new (size_t dfl_size)
string->fd = -1;
string->mmapped_size = 0;
- if (mmap_string_maybe_expand (string, MAX (dfl_size, 2)) == NULL)
+ if (mmap_string_maybe_expand (string, MAX (dfl_size, 2)) == NULL) {
+ free(string);
return NULL;
+ }
- if (string->str == NULL)
+ if (string->str == NULL) {
+ free(string);
return NULL;
+ }
string->str[0] = '\0';