]> git.wh0rd.org Git - nano.git/commitdiff
Plugging two tiny memory leaks. Patch essentially by Mark Majeres.
authorBenno Schulenberg <bensberg@justemail.net>
Sun, 27 Apr 2014 11:29:50 +0000 (11:29 +0000)
committerBenno Schulenberg <bensberg@justemail.net>
Sun, 27 Apr 2014 11:29:50 +0000 (11:29 +0000)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@4819 35c25a1d-7b9e-4130-9fde-d3aeb78583b8

ChangeLog
src/rcfile.c

index e2e228f0b75bc3cc59cc67c5acd2eb82bb23715a..2e2742e4ed6f0744dc87a25ccf73161243b8ee78 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,6 @@
+2014-04-27  Mark Majeres  <mark@engine12.com>
+       * src/rcfile.c (parse_include): Plug two tiny memory leaks.
+
 2014-04-26  Benno Schulenberg  <bensberg@justemail.net>
        * src/global.c (add_to_funcs): Add a pointer to the tail of the
        functions list, to simplify and speed up adding new items.  And
index f5f1e947e80a93a4ce1c88d6bcf2cda369b04002..7ee4d48c82eeced201a610b60b64e6ef55771f3f 100644 (file)
@@ -649,6 +649,9 @@ void parse_include(char *ptr)
                strerror(errno));
     }
 
+    globfree(&files);
+    free(expanded);
+
     /* We're done with the new syntax file.  Restore the original
      * filename and line number position. */
     nanorc = nanorc_save;