[PATCH] fix memory leaks in notmuch-show.c:format_headers_sprinter()
jestedfa at microsoft.com
Thu Mar 16 09:53:47 PDT 2017
Was just grepping through notmuch sources and discovered what I think are memory leaks in notmuch-show.c’s format_headers_sprinter() code.
Internet_address_list_to_string() and g_mime_message_get_date_as_string() return allocated string buffers and not const, so from what I can tell from taking a look at the sprinter-sexp.c’s sexp_string() function, the code leaks the recipients_string as well as the date string.
Attached is a patch which fixes these leaks.
Hope this helps,
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 1747 bytes
More information about the notmuch