]> diplodocus.org Git - nmh/commitdiff
mhfixmsg.c: Fix memory leak of temporary filename if write fails.
authorRalph Corderoy <ralph@inputplus.co.uk>
Mon, 11 Sep 2017 23:07:50 +0000 (00:07 +0100)
committerRalph Corderoy <ralph@inputplus.co.uk>
Mon, 11 Sep 2017 23:07:50 +0000 (00:07 +0100)
uip/mhfixmsg.c

index 6a7a048..2bbb045 100644 (file)
@@ -2292,6 +2292,7 @@ strip_crs (CT ct, int *message_mods) {
                     inform("unable to write temporary file %s, continuing...",
                               stripped_content_file);
                     (void) m_unlink (stripped_content_file);
+                    free(stripped_content_file);
                     status = NOTOK;
                 } else {
                     /* Replace the decoded file with the converted one. */