PowerManager: Fix build

fix build breaks by commit 667372e39bfe01bd15f0803d51ef0e9816f18808

Change-Id: I9e6e0f9146f860d27337cef0551c686ba2d60e23
This commit is contained in:
Ruchi Kandoi
2014-04-04 16:25:54 -07:00
parent 6652b98339
commit 654d75fec9

View File

@@ -190,8 +190,14 @@ static void nativeSetAutoSuspend(JNIEnv *env, jclass clazz, jboolean enable) {
}
static void nativeSendPowerHint(JNIEnv *env, jclass clazz, jint hintId, jint data) {
int data_param = data;
if (gPowerModule && gPowerModule->powerHint) {
gPowerModule->powerHint(gPowerModule, (power_hint_t)hintId, (void *)data);
if(data)
gPowerModule->powerHint(gPowerModule, (power_hint_t)hintId, &data_param);
else {
gPowerModule->powerHint(gPowerModule, (power_hint_t)hintId, NULL);
}
}
}