Skip to contentSkip to conversation

libsensors4: Make

PATCH In review Jean Delvare 2 participants 2 messages Jul 24, 2007 – Jul 25, 2007 Library code

lore
Share & tools
lore
#0 lore raw

PATCH 1/2 libsensors4: Make

Don't export sensors_chip_name_has_wildcards(). I don't know of any application using it, and I can't think of any use case for it outside of libsensors. I'm not even sure if the inside calls are all legitimate.

Hans, can you please check if gnome sensors-applet or gkrellm use this function?

---
 lib/access.c     |    2 +-
 lib/libsensors.3 |    6 ------
 lib/sensors.h    |    5 -----
 3 files changed, 1 insertion(+), 12 deletions(-)
lib/access.c +1 -1
@@ -132,7 +132,7 @@ sensors_lookup_feature_name(const sensor
 /* Check whether the chip name is an 'absolute' name, which can only match
    one chip, or whether it has wildcards. Returns 0 if it is absolute, 1
    if there are wildcards. */
-int sensors_chip_name_has_wildcards(sensors_chip_name chip)
+static int sensors_chip_name_has_wildcards(sensors_chip_name chip)
 {
 	if ((chip.prefix = SENSORS_CHIP_NAME_PREFIX_ANY) ||
 	    (chip.bus = SENSORS_CHIP_NAME_BUS_ANY) ||
lib/libsensors.3 +0 -6
@@ -37,7 +37,6 @@ libsensors \- publicly accessible functi
                             \fBsensors_chip_name *res);\fP
 .B int sensors_match_chip(sensors_chip_name chip1, 
                        \fBsensors_chip_name chip2);\fP
-.B int sensors_chip_name_has_wildcards(sensors_chip_name chip);
 .B const char *sensors_get_adapter_name(int bus_nr);
 .B int sensors_get_label(sensors_chip_name name, int feature, 
                       \fBchar **result);\fP
@@ -72,11 +71,6 @@ Parse a chip name to the internal repres
 .br
 Compare two chips name descriptions, to see whether they could match. Return 0 if it does not match, return 1 if it does match.
 
-\fBint sensors_chip_name_has_wildcards
-    (sensors_chip_name chip);\fP
-.br
-Check whether the chip name is an 'absolute' name, which can only match one chip, or whether it has wildcards. Returns 0 if it is absolute, 1 if there are wildcards.
-
 .B const char *sensors_get_adapter_name(int bus_nr);
 .br
 This function returns the adapter name of a bus number, as used within the
lib/sensors.h +0 -5
@@ -66,11 +66,6 @@ extern int sensors_parse_chip_name(const
 extern int sensors_match_chip(sensors_chip_name chip1, 
                               sensors_chip_name chip2);
 
-/* Check whether the chip name is an 'absolute' name, which can only match
-   one chip, or whether it has wildcards. Returns 0 if it is absolute, 1
-   if there are wildcards. */
-extern int sensors_chip_name_has_wildcards(sensors_chip_name chip);
-
 /* This function returns the adapter name of a bus number,
    as used within the sensors_chip_name structure. If it could not be found, 
    it returns NULL */
Signature · 6 lines
Jean Delvare

_______________________________________________
lm-sensors mailing list
[email protected]
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors
#1 lore raw
Quoted 7 lines · Jean Delvare

Don't export sensors_chip_name_has_wildcards(). I don't know of any application using it, and I can't think of any use case for it outside of libsensors. I'm not even sure if the inside calls are all legitimate.

Hans, can you please check if gnome sensors-applet or gkrellm use this function?

This function isn't used be gkrellm, gnome sensors-applet or ksensors.

Regards,

Hans

_______________________________________________
lm-sensors mailing list
[email protected]
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors