mirror of https://github.com/BOINC/boinc.git
*** empty log message ***
svn path=/trunk/boinc/; revision=5225
This commit is contained in:
parent
76106f946e
commit
0054cd575f
|
@ -380,8 +380,8 @@ bool HOST_INFO::host_is_running_on_batteries() {
|
||||||
// battery is charging or missing and make that part
|
// battery is charging or missing and make that part
|
||||||
// of the decision.
|
// of the decision.
|
||||||
bool bIsOnBatteryPower = (pStatus.ACLineStatus != 1);
|
bool bIsOnBatteryPower = (pStatus.ACLineStatus != 1);
|
||||||
bool bIsBatteryCharging = (pStatus.BatteryFlag & 8)
|
bool bIsBatteryCharging = ((pStatus.BatteryFlag & 8) == 8);
|
||||||
bool bIsBatteryMissing = (pStatus.BatteryFlag & 128)
|
bool bIsBatteryMissing = ((pStatus.BatteryFlag & 128) == 128);
|
||||||
|
|
||||||
return (bIsOnBatteryPower && !bIsBatteryCharging && !bIsBatteryMissing);
|
return (bIsOnBatteryPower && !bIsBatteryCharging && !bIsBatteryMissing);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue