|
From: | Robert Kausch |
Subject: | Re: [Libcdio-devel] memory leak in cdio_free() |
Date: | Mon, 15 Jun 2015 19:09:20 +0200 |
User-agent: | Mozilla/5.0 (Windows NT 6.1; WOW64; rv:36.0) Gecko/20100101 Thunderbird/36.0 |
Just found this mail and saw that the issue was still open. Fixed it now. Thank you for spotting this! Robert ---- Robert Kausch address@hidden Am 31.10.2014 um 19:49 schrieb Pete Batard:
Hi, The following in memory.c [1] looks like an unfortunate typo: if (p_memory != NULL) return;The result is that cdio_free() currently leaks every block of memory it should deallocate... :(On a side note, free() is supposed to accept NULL as a pointer ([2] "If ptr is NULL, no operation is performed."), so the check for NULL could probably be avoided.Regards, /Pete[1] http://git.savannah.gnu.org/gitweb/?p=libcdio.git;a=blob;f=lib/driver/memory.c#l39[2] http://linux.die.net/man/3/free
[Prev in Thread] | Current Thread | [Next in Thread] |