You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@geode.apache.org by nn...@apache.org on 2017/12/11 21:38:35 UTC
[geode] branch develop updated: GEODE-4072: Fixed race condition in
AckThreadReader shutdown.
This is an automated email from the ASF dual-hosted git repository.
nnag pushed a commit to branch develop
in repository https://gitbox.apache.org/repos/asf/geode.git
The following commit(s) were added to refs/heads/develop by this push:
new 107eae6 GEODE-4072: Fixed race condition in AckThreadReader shutdown.
107eae6 is described below
commit 107eae6af59241d3ed72ea4b43f3d48d27740732
Author: nabarun <nn...@pivotal.io>
AuthorDate: Fri Dec 8 15:41:27 2017 -0800
GEODE-4072: Fixed race condition in AckThreadReader shutdown.
* The global connection variable may be set to null by another thread.
* Assign the local variable to the connection variable and then perform all the null checks on that local variable.
---
.../geode/internal/cache/wan/GatewaySenderEventRemoteDispatcher.java | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/geode-wan/src/main/java/org/apache/geode/internal/cache/wan/GatewaySenderEventRemoteDispatcher.java b/geode-wan/src/main/java/org/apache/geode/internal/cache/wan/GatewaySenderEventRemoteDispatcher.java
index a86f430..3a15342 100644
--- a/geode-wan/src/main/java/org/apache/geode/internal/cache/wan/GatewaySenderEventRemoteDispatcher.java
+++ b/geode-wan/src/main/java/org/apache/geode/internal/cache/wan/GatewaySenderEventRemoteDispatcher.java
@@ -749,8 +749,8 @@ public class GatewaySenderEventRemoteDispatcher implements GatewaySenderEventDis
// we need to destroy connection irrespective of we are listening on it or
// not. No need to take lock as the reader thread may be blocked and we might not
// get chance to destroy unless that returns.
- if (connection != null) {
- Connection conn = connection;
+ Connection conn = connection;
+ if (conn != null) {
shutDownAckReaderConnection();
if (!conn.isDestroyed()) {
conn.destroy();
--
To stop receiving notification emails like this one, please contact
['"commits@geode.apache.org" <co...@geode.apache.org>'].