Changeset 5175

Show
Ignore:
Timestamp:
04/11/08 22:41:31 (6 years ago)
Author:
khali
Message:

We start at the end of the chip list, going backwards, and we want the
late compute statements to override the early ones (as documented in the
sensors.conf manual page), so we must stop as soon as any match is found.

This fixes Debian bug #474596:
 http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=474596

Location:
lm-sensors/branches/lm-sensors-3.0.0
Files:
2 modified

Legend:

Unmodified
Added
Removed
  • lm-sensors/branches/lm-sensors-3.0.0/CHANGES

    r5169 r5175  
    55  libsensors: Use __func__ instead of __FUNCTION__ 
    66              Parse the configuration file in C locale 
     7              Late compute statements override early ones 
    78  sensors-detect: Add SMSC SCH5027D detection 
    89                  Do not access I/O ports on PPC 
  • lm-sensors/branches/lm-sensors-3.0.0/lib/access.c

    r5163 r5175  
    250250 
    251251                chip = NULL; 
    252                 while ((chip = sensors_for_all_config_chips(name, chip))) 
     252                while (!expr && 
     253                       (chip = sensors_for_all_config_chips(name, chip))) 
    253254                        for (i = 0; i < chip->computes_count; i++) { 
    254255                                if (!strcmp(feature->name, 
     
    301302 
    302303                chip = NULL; 
    303                 while ((chip = sensors_for_all_config_chips(name, chip))) 
     304                while (!expr && 
     305                       (chip = sensors_for_all_config_chips(name, chip))) 
    304306                        for (i = 0; i < chip->computes_count; i++) { 
    305307                                if (!strcmp(feature->name,