Reduce wake lock refresh interval to 1 minute.

This commit is contained in:
akwizgran
2018-05-14 16:50:18 +01:00
parent 4f732c3997
commit d7f39af6d1

View File

@@ -105,7 +105,7 @@ class TorPlugin implements DuplexPlugin, EventHandler, EventListener {
private static final String OWNER = "__OwningControllerProcess";
private static final int COOKIE_TIMEOUT = 3000; // Milliseconds
private static final Pattern ONION = Pattern.compile("[a-z2-7]{16}");
// This tag will prevent Huawei's power manager from killing us
// This tag may prevent Huawei's power manager from killing us
private static final String WAKE_LOCK_TAG = "LocationManagerService";
private static final Logger LOG =
Logger.getLogger(TorPlugin.class.getName());
@@ -164,7 +164,7 @@ class TorPlugin implements DuplexPlugin, EventHandler, EventListener {
PowerManager pm = (PowerManager)
appContext.getSystemService(POWER_SERVICE);
wakeLock = new RenewableWakeLock(pm, scheduler, PARTIAL_WAKE_LOCK,
WAKE_LOCK_TAG, 30, MINUTES);
WAKE_LOCK_TAG, 1, MINUTES);
}
@Override