mirror of
https://github.com/M66B/FairEmail.git
synced 2026-04-01 14:46:31 +02:00
Wait 50 ms after gc
This commit is contained in:
@@ -1667,6 +1667,15 @@ public class Helper {
|
||||
|
||||
// Miscellaneous
|
||||
|
||||
static void gc() {
|
||||
Runtime.getRuntime().gc();
|
||||
try {
|
||||
Thread.sleep(50);
|
||||
} catch (InterruptedException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
|
||||
static <T> List<List<T>> chunkList(List<T> list, int size) {
|
||||
List<List<T>> result = new ArrayList<>(list.size() / size);
|
||||
for (int i = 0; i < list.size(); i += size)
|
||||
|
||||
Reference in New Issue
Block a user