Hardware/HDD/HDDGroup.cs
changeset 48 eb04985b7b6a
parent 2 105939e4eb7e
child 165 813d8bc3192f
     1.1 --- a/Hardware/HDD/HDDGroup.cs	Tue Feb 16 21:44:25 2010 +0000
     1.2 +++ b/Hardware/HDD/HDDGroup.cs	Wed Feb 17 18:48:27 2010 +0000
     1.3 @@ -67,12 +67,24 @@
     1.4                  continue;
     1.5  
     1.6                int attribute = -1;
     1.7 -              for (int i = 0; i < attributes.Length; i++) {
     1.8 +              for (int i = 0; i < attributes.Length; i++) 
     1.9                  if (attributes[i].ID == SMART.AttributeID.Temperature) {
    1.10                    attribute = i;
    1.11                    break;
    1.12                  }
    1.13 -              }
    1.14 +              if (attribute == -1) 
    1.15 +                for (int i = 0; i < attributes.Length; i++)
    1.16 +                  if (attributes[i].ID == SMART.AttributeID.DriveTemperature) {
    1.17 +                    attribute = i;
    1.18 +                    break;
    1.19 +                  }
    1.20 +              if (attribute == -1)
    1.21 +                for (int i = 0; i < attributes.Length; i++)
    1.22 +                  if (attributes[i].ID == SMART.AttributeID.AirflowTemperature) 
    1.23 +                  {
    1.24 +                    attribute = i;
    1.25 +                    break;
    1.26 +                  }
    1.27  
    1.28                if (attribute >= 0) {
    1.29                  hardware.Add(new HDD(name, handle, drive, attribute));