From 77707737df4f25c45b66bfac80f0b1895af686b0 Mon Sep 17 00:00:00 2001 From: Florian Schmaus Date: Mon, 11 Jun 2018 18:24:15 +0200 Subject: [PATCH] Make StanzaCollector's cancelled field volatile --- .../src/main/java/org/jivesoftware/smack/StanzaCollector.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/smack-core/src/main/java/org/jivesoftware/smack/StanzaCollector.java b/smack-core/src/main/java/org/jivesoftware/smack/StanzaCollector.java index 5c6ed9784..202ef25a1 100644 --- a/smack-core/src/main/java/org/jivesoftware/smack/StanzaCollector.java +++ b/smack-core/src/main/java/org/jivesoftware/smack/StanzaCollector.java @@ -1,6 +1,6 @@ /** * - * Copyright 2003-2007 Jive Software, 2016-2017 Florian Schmaus. + * Copyright 2003-2007 Jive Software, 2016-2018 Florian Schmaus. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -55,7 +55,7 @@ public class StanzaCollector { private final Stanza request; - private boolean cancelled = false; + private volatile boolean cancelled = false; /** * Creates a new stanza collector. If the stanza filter is null, then