summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew John Hughes <gnu_andrew@member.fsf.org>2008-09-17 23:44:19 +0000
committerAndrew John Hughes <gnu_andrew@member.fsf.org>2008-09-17 23:44:19 +0000
commitc633b2f6a0121fa45380a7c5c2071e05fec6808a (patch)
tree67ea73be6d176b334d8d43ccb1e3b01ca44d474f
parent98a6bf8245b026ac975b529568ebd3e06e656ed4 (diff)
downloadclasspath-c633b2f6a0121fa45380a7c5c2071e05fec6808a.tar.gz
Reinstate use of EnvironmentMap.
2008-09-16 Andrew John Hughes <gnu_andrew@member.fsf.org> * java/lang/System.java (getenv): Reinstate use of EnvironmentMap as opposed to raw HashMap.
-rw-r--r--ChangeLog10
-rw-r--r--java/lang/System.java6
2 files changed, 11 insertions, 5 deletions
diff --git a/ChangeLog b/ChangeLog
index e381c0faa..2d44c148b 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,7 +1,13 @@
+2008-09-16 Andrew John Hughes <gnu_andrew@member.fsf.org>
+
+ * java/lang/System.java (getenv): Reinstate
+ use of EnvironmentMap as opposed to raw
+ HashMap.
+
2008-09-16 Mario Torre <neugens@aicas.com>
- * java/lang/System.java (getenv): Fix env entries of the form
- key=value=value=value not parsed correctly.
+ * java/lang/System.java (getenv): Fix env entries of the form
+ key=value=value=value not parsed correctly.
2008-09-15 Andrew John Hughes <gnu_andrew@member.fsf.org>
diff --git a/java/lang/System.java b/java/lang/System.java
index 6be313155..58b1bbad3 100644
--- a/java/lang/System.java
+++ b/java/lang/System.java
@@ -549,7 +549,7 @@ public final class System
if (environmentMap == null)
{
- Map<String, String> _map = new HashMap();
+ Map<String,String> variables = new EnvironmentMap();
List<String> environ = (List<String>)VMSystem.environ();
for (String envEntry : environ)
{
@@ -561,11 +561,11 @@ public final class System
int equalSignIndex = envEntry.indexOf('=');
String key = envEntry.substring(0, equalSignIndex);
String value = envEntry.substring(equalSignIndex + 1);
- _map.put(key, value);
+ variables.put(key, value);
}
}
- environmentMap = Collections.unmodifiableMap(_map);
+ environmentMap = Collections.unmodifiableMap(variables);
}
return environmentMap;