fix 2 leaks found by valgrind - missing some free() during cleanup

(as opposed to ongoing run-time leaks)


git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@3293 7894878c-1315-0410-8ee3-d5d059ff63e0
This commit is contained in:
Mark M. Hoffman committed 2006-05-15 03:06:05 +00:00
1 parent fd2023d0cf
commit e620cb652c
1 file changed
+5
+5
View File
@@ -106,6 +106,11 @@ void free_chip(sensors_chip chip)
{
int i;
for (i = 0; i < chip.chips.fits_count; i++)
free_chip_name(chip.chips.fits[i]);
free(chip.chips.fits);
chip.chips.fits_count = chip.chips.fits_max = 0;
for (i = 0; i < chip.labels_count; i++)
free_label(chip.labels[i]);
free(chip.labels);