aboutsummaryrefslogtreecommitdiffstats
path: root/src/main/java/eu/siacs/conversations/services/NotificationService.java
diff options
context:
space:
mode:
authorDaniel Gultsch <daniel@gultsch.de>2016-01-04 20:14:29 +0100
committerDaniel Gultsch <daniel@gultsch.de>2016-01-04 20:14:29 +0100
commitc3e2d2cfba9813b217d5606607f207449d2e6d20 (patch)
treee00f6170c4941838f6e70db915c85e9c425132f5 /src/main/java/eu/siacs/conversations/services/NotificationService.java
parentfb97f9d18f4a4152983ffbbfa2bae5881f3f22ce (diff)
added missing synchronize when pushing messages from mam backlog
Diffstat (limited to 'src/main/java/eu/siacs/conversations/services/NotificationService.java')
-rw-r--r--src/main/java/eu/siacs/conversations/services/NotificationService.java4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/main/java/eu/siacs/conversations/services/NotificationService.java b/src/main/java/eu/siacs/conversations/services/NotificationService.java
index 624c0a60..3199b492 100644
--- a/src/main/java/eu/siacs/conversations/services/NotificationService.java
+++ b/src/main/java/eu/siacs/conversations/services/NotificationService.java
@@ -115,7 +115,9 @@ public class NotificationService {
public void pushFromBacklog(final Message message) {
if (notify(message)) {
- pushToStack(message);
+ synchronized (notifications) {
+ pushToStack(message);
+ }
}
}