Skip to content

Commit b7d4048

Browse files
xNombreiqbal
authored andcommitted
Revert "Fix high battery drain after using flashlight After turning off the flashlight via the tile, the camera is kept open, preventing the device from entering deep sleep (and destroying battery life)."
This reverts commit 31e163657471e829a1f227ca69dd01b06ebeaaae. Assigning NULL to sp will eventually execute its destructor. Signed-off-by: xNombre <kartapolska@gmail.com>
1 parent fb7423a commit b7d4048

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

services/camera/libcameraservice/CameraFlashlight.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -587,7 +587,7 @@ status_t CameraHardwareInterfaceFlashControl::disconnectCameraDevice() {
587587
}
588588
mDevice->setPreviewWindow(NULL);
589589
mDevice->release();
590-
mDevice.clear();
590+
mDevice = NULL;
591591

592592
return OK;
593593
}

0 commit comments

Comments
 (0)