diff --git a/src/conky.h b/src/conky.h index 33a829ef..970f0d15 100644 --- a/src/conky.h +++ b/src/conky.h @@ -591,14 +591,14 @@ int get_laptop_mode(void); void update_gateway_info(void); int open_sysfs_sensor(const char *dir, const char *dev, const char *type, int n, - int *div, char *devtype); + int *divisor, char *devtype); -#define open_i2c_sensor(dev, type, n, div, devtype) \ - open_sysfs_sensor("/sys/bus/i2c/devices/", dev, type, n, div, devtype) -#define open_platform_sensor(dev, type, n, div, devtype) \ - open_sysfs_sensor("/sys/bus/platform/devices/", dev, type, n, div, devtype) -#define open_hwmon_sensor(dev, type, n, div, devtype) \ - open_sysfs_sensor("/sys/class/hwmon/", dev, type, n, div, devtype) +#define open_i2c_sensor(dev, type, n, divisor, devtype) \ + open_sysfs_sensor("/sys/bus/i2c/devices/", dev, type, n, divisor, devtype) +#define open_platform_sensor(dev, type, n, divisor, devtype) \ + open_sysfs_sensor("/sys/bus/platform/devices/", dev, type, n, divisor, devtype) +#define open_hwmon_sensor(dev, type, n, divisor, devtype) \ + open_sysfs_sensor("/sys/class/hwmon/", dev, type, n, divisor, devtype) double get_sysfs_info(int *fd, int arg, char *devtype, char *type); diff --git a/src/linux.c b/src/linux.c index 4576c93d..54496561 100644 --- a/src/linux.c +++ b/src/linux.c @@ -261,7 +261,7 @@ END_TRUE: x = strndup(y, text_buffer_size); \ } -void update_gateway_info_failure(char *reason) +void update_gateway_info_failure(const char *reason) { if(reason != NULL) { perror(reason);