projects
/
neomutt
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
c63f828
)
imap: Fix mx.mbox leak in imap_get_parent_path
808/head
author
Jelle van der Waa
<jelle@vdwaa.nl>
Sun, 1 Oct 2017 16:48:34 +0000
(18:48 +0200)
committer
Richard Russon
<rich@flatcap.org>
Mon, 2 Oct 2017 11:30:09 +0000
(12:30 +0100)
valgrind reports a memory leak in imap_get_parent_path due to no
free'ing mx.mbox. As described in imap_parse_path, the callee should
free mx.mbox.
imap/util.c
patch
|
blob
|
history
diff --git
a/imap/util.c
b/imap/util.c
index 2945e8b376b9901c8c01d7455c4db05a155497ff..6d6acce3cbdce8c057b4fb6029d0887dec8edfb7 100644
(file)
--- a/
imap/util.c
+++ b/
imap/util.c
@@
-166,6
+166,7
@@
void imap_get_parent_path(char *output, const char *path, size_t olen)
/* Returns a fully qualified IMAP url */
imap_qualify_path(output, olen, &mx, mbox);
+ FREE(&mx.mbox);
}
/**