From 98365e78d0700c498a7d7da42bb6b3522ab02184 Mon Sep 17 00:00:00 2001
From: Ludovic Poitou <ludovic.poitou@forgerock.com>
Date: Fri, 30 Aug 2013 10:24:00 +0000
Subject: [PATCH] Fix typo in comment and avoid possible NPE in debugging mode.
---
opends/src/server/org/opends/server/extensions/TraditionalWorkerThread.java | 9 ++++-----
1 files changed, 4 insertions(+), 5 deletions(-)
diff --git a/opends/src/server/org/opends/server/extensions/TraditionalWorkerThread.java b/opends/src/server/org/opends/server/extensions/TraditionalWorkerThread.java
index bc73665..cb64c4f 100644
--- a/opends/src/server/org/opends/server/extensions/TraditionalWorkerThread.java
+++ b/opends/src/server/org/opends/server/extensions/TraditionalWorkerThread.java
@@ -305,7 +305,7 @@
}
/**
- * Retrieves any relevent debug information with which this tread is
+ * Retrieves any relevant debug information with which this tread is
* associated so they can be included in debug messages.
*
* @return debug information about this thread as a string.
@@ -314,10 +314,9 @@
public Map<String, String> getDebugProperties()
{
Map<String, String> properties = super.getDebugProperties();
- properties.put("clientConnection",
- operation.getClientConnection().toString());
- properties.put("operation", operation.toString());
-
+ properties.put("clientConnection", operation != null
+ ? String.valueOf(operation.getClientConnection()) : "none");
+ properties.put("operation", String.valueOf(operation));
return properties;
}
}
--
Gitblit v1.10.0