summaryrefslogtreecommitdiff
path: root/lib/init.c
diff options
context:
space:
mode:
authorJean Delvare <khali@linux-fr.org>2007-09-23 12:05:16 +0000
committerJean Delvare <khali@linux-fr.org>2007-09-23 12:05:16 +0000
commit96c914bfdaefe98a0e342b999f4e006e77ae7bc1 (patch)
tree87fb1fd1c72a1bcdb041360f35299a8f1de731b7 /lib/init.c
parentbfe337fe76aa796fae800b5c3f53b9b483d0efaf (diff)
downloadlm-sensors-git-96c914bfdaefe98a0e342b999f4e006e77ae7bc1.tar.gz
Define a separate structure to represent main features. This allows
for faster main features lookup. One side effect of this change is that subfeatures can no longer have labels nor be ignored. I do not think that this is a problem in practice, and actually this makes a lot of sense. git-svn-id: http://lm-sensors.org/svn/lm-sensors/branches/lm-sensors-3.0.0@4834 7894878c-1315-0410-8ee3-d5d059ff63e0
Diffstat (limited to 'lib/init.c')
-rw-r--r--lib/init.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/init.c b/lib/init.c
index adf928b1..94f078eb 100644
--- a/lib/init.c
+++ b/lib/init.c
@@ -59,6 +59,9 @@ static void free_chip_features(sensors_chip_features *features)
for (i = 0; i < features->subfeature_count; i++)
free(features->subfeature[i].name);
free(features->subfeature);
+ for (i = 0; i < features->feature_count; i++)
+ free(features->feature[i].name);
+ free(features->feature);
}
static void free_bus(sensors_bus *bus)