Fix compile warning

Fix crash if smc failed to get current authorization during first use
This commit is contained in:
Anakin Zheng
2014-03-25 15:13:47 -04:00
parent 063d53b06c
commit 3dbea4bd98
6 changed files with 68 additions and 31 deletions

View File

@ -107,7 +107,7 @@ static NSArray *allSensors = nil;
SMCVal_t val;
int totalFans;
SMCReadKey2("FNum", &val,conn);
totalFans = _strtoul(val.bytes, val.dataSize, 10);
totalFans = _strtoul((char *)val.bytes, val.dataSize, 10);
return totalFans;
}