2
0
mirror of https://github.com/lm-sensors/lm-sensors synced 2025-09-03 07:45:30 +00:00

Return with an explicit error code/message if sysfs isn't mounted.

git-svn-id: http://lm-sensors.org/svn/lm-sensors/branches/lm-sensors-3.0.0@4464 7894878c-1315-0410-8ee3-d5d059ff63e0
This commit is contained in:
Jean Delvare
2007-06-25 13:58:55 +00:00
parent f8c7f20bf1
commit f00aef9271
3 changed files with 14 additions and 10 deletions

View File

@@ -237,12 +237,7 @@ int main (int argc, char *argv[])
open_config_file(config_file_name);
if ((res = sensors_init(config_file))) {
fprintf(stderr,"%s\n",sensors_strerror(res));
if (res == -SENSORS_ERR_PROC)
fprintf(stderr,
"Kernel interface access error\n"
"For 2.6 kernels, make sure you have mounted sysfs and libsensors\n"
"was compiled with sysfs support!\n");
fprintf(stderr, "sensors_init: %s\n", sensors_strerror(res));
exit(1);
}
close_config_file(config_file_name);