From 270160781026de7a9fbed3a6d9e98faa24e2ecda Mon Sep 17 00:00:00 2001 From: Greyson Parrelli Date: Tue, 16 Apr 2019 09:52:12 -0400 Subject: [PATCH] Reduce the possible number of unique jobs to avoid crash. Some devices have a limit of 100 unique JobScheduler jobs. Previously we allowed up to 1,000. Given that we just need _some_ job running, I lowered the limit to 75 to give us some head room. --- .../securesms/jobmanager/JobSchedulerScheduler.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/org/thoughtcrime/securesms/jobmanager/JobSchedulerScheduler.java b/src/org/thoughtcrime/securesms/jobmanager/JobSchedulerScheduler.java index 8e9fe53c43..77a1f9a7bb 100644 --- a/src/org/thoughtcrime/securesms/jobmanager/JobSchedulerScheduler.java +++ b/src/org/thoughtcrime/securesms/jobmanager/JobSchedulerScheduler.java @@ -24,7 +24,7 @@ public class JobSchedulerScheduler implements Scheduler { private static final String PREF_NAME = "JobSchedulerScheduler_prefs"; private static final String PREF_NEXT_ID = "pref_next_id"; - private static final int MAX_ID = 1000; + private static final int MAX_ID = 75; private final Application application;