1
0
mirror of https://github.com/gryf/wmtemp.git synced 2025-12-17 19:40:27 +01:00

Fix for commented out paths for temperature input in config

This commit is contained in:
2017-01-04 10:53:09 +01:00
parent bc93777806
commit e89b081f45

View File

@@ -230,31 +230,31 @@ void parse_config(struct config *conf) {
strncpy (value, item, MAXLEN);
strip(value);
if (!strcmp(name, "cpu1_path")){
if (strncmp(name, "cpu1_path", 9) == 0){
free(cfg.cpu1.path);
cfg.cpu1.path = malloc(sizeof(value) + 1);
strcpy(cfg.cpu1.path, value);
}
if (!strcmp(name, "cpu2_path")){
if (strncmp(name, "cpu2_path", 9) == 0){
free(cfg.cpu2.path);
cfg.cpu2.path = malloc(sizeof(value) + 1);
strcpy(cfg.cpu2.path, value);
}
if (!strcmp(name, "cpu1_path")){
if (strncmp(name, "cpu3_path", 9) == 0){
free(cfg.cpu3.path);
cfg.cpu3.path = malloc(sizeof(value) + 1);
strcpy(cfg.cpu3.path, value);
}
if (!strcmp(name, "cpu1_path")){
if (strncmp(name, "cpu4_path", 9) == 0){
free(cfg.cpu4.path);
cfg.cpu4.path = malloc(sizeof(value) + 1);
strcpy(cfg.cpu4.path, value);
}
if (!strcmp(name, "gpu_path")){
if (strncmp(name, "gpu_path", 8) == 0){
free(cfg.gpu.path);
cfg.gpu.path = malloc(sizeof(value) + 1);
strcpy(cfg.gpu.path, value);