Fix NULL handling for PTMU_GetBatteryLevel() and PTMU_GetBatteryChargeState().