Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorIgor Fedorenko2014-07-29 23:16:11 -0400
committerIgor Fedorenko2014-07-29 23:16:11 -0400
commit4b83a0f17e307dbc9ed5554ee6f41c5eeff4206e (patch)
tree4f3b34e18a65093d3ba5a777e3f1578124eb6681 /org.eclipse.m2e.logback.configuration/src
parent04dade2a891c158558ea8aebe36e5c8ba2dbe111 (diff)
downloadm2e-core-4b83a0f17e307dbc9ed5554ee6f41c5eeff4206e.tar.gz
m2e-core-4b83a0f17e307dbc9ed5554ee6f41c5eeff4206e.tar.xz
m2e-core-4b83a0f17e307dbc9ed5554ee6f41c5eeff4206e.zip
440696 guard against ConcurrentModificationException during Properties.entrySet
Change-Id: Ida19217c41836ef788a7a25913b9c5388fe460fc Signed-off-by: Igor Fedorenko <igor@ifedorenko.com>
Diffstat (limited to 'org.eclipse.m2e.logback.configuration/src')
-rw-r--r--org.eclipse.m2e.logback.configuration/src/org/eclipse/m2e/logback/configuration/LogHelper.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/org.eclipse.m2e.logback.configuration/src/org/eclipse/m2e/logback/configuration/LogHelper.java b/org.eclipse.m2e.logback.configuration/src/org/eclipse/m2e/logback/configuration/LogHelper.java
index 2621be1b..6a49fa25 100644
--- a/org.eclipse.m2e.logback.configuration/src/org/eclipse/m2e/logback/configuration/LogHelper.java
+++ b/org.eclipse.m2e.logback.configuration/src/org/eclipse/m2e/logback/configuration/LogHelper.java
@@ -22,8 +22,8 @@ public class LogHelper {
public static void logJavaProperties(Logger log) {
Properties javaProperties = System.getProperties();
SortedMap<String, String> sortedProperties = new TreeMap<String, String>();
- for(Object key : javaProperties.keySet()) {
- sortedProperties.put((String) key, (String) javaProperties.get(key));
+ for(String key : javaProperties.stringPropertyNames()) {
+ sortedProperties.put(key, javaProperties.getProperty(key));
}
log.debug("Java properties (ordered by property name):"); //$NON-NLS-1$
for(String key : sortedProperties.keySet()) {

Back to the top