From f7c840cffc60b7681f525ea1a850ac8d923a3236 Mon Sep 17 00:00:00 2001 From: M66B Date: Wed, 10 Mar 2021 20:25:56 +0100 Subject: [PATCH] Disable gc --- app/src/main/java/eu/faircode/email/Helper.java | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/app/src/main/java/eu/faircode/email/Helper.java b/app/src/main/java/eu/faircode/email/Helper.java index 4c43d90437..623d4ed950 100644 --- a/app/src/main/java/eu/faircode/email/Helper.java +++ b/app/src/main/java/eu/faircode/email/Helper.java @@ -1672,11 +1672,13 @@ public class Helper { // Miscellaneous static void gc() { - Runtime.getRuntime().gc(); - try { - Thread.sleep(50); - } catch (InterruptedException e) { - e.printStackTrace(); + if (BuildConfig.DEBUG) { + Runtime.getRuntime().gc(); + try { + Thread.sleep(50); + } catch (InterruptedException e) { + e.printStackTrace(); + } } }