]> git.notmuchmail.org Git - notmuch/commitdiff
Free the results of scandir()
authorEthan Glasser-Camp <ethan@betacantrips.com>
Tue, 7 Feb 2012 10:05:03 +0000 (05:05 -0500)
committerDavid Bremner <bremner@debian.org>
Wed, 15 Feb 2012 03:44:30 +0000 (23:44 -0400)
scandir() returns "strings allocated via malloc(3)" which are then
"collected in array namelist which is allocated via
malloc(3)". Currently we just free the array namelist. Instead, free
all the entries of namelist, and then free namelist.

entry only points to elements of namelist, so we don't free it
separately.


No differences found