PatchSet 4757 Date: 2004/05/20 19:08:47 Author: dalibor Branch: HEAD Tag: (none) Log: Resynced with GNU Classpath: Fix for Throwable
2004-05-20 Dalibor Topic <[EMAIL PROTECTED]> * libraries/javalib/java/lang/Throwable.java: Resynced with GNU Classpath. * libraries/javalib/java/lang/System.java: (props) Renamed into properties. Made package private. 2004-05-20 Mark Wielaard <[EMAIL PROTECTED]> * java/lang/Throwable.java (StaticData.nl): Initialize through directly accessing System.properties.getProperty(). Members: ChangeLog:1.2328->1.2329 libraries/javalib/java/lang/System.java:1.36->1.37 libraries/javalib/java/lang/Throwable.java:1.12->1.13 Index: kaffe/ChangeLog diff -u kaffe/ChangeLog:1.2328 kaffe/ChangeLog:1.2329 --- kaffe/ChangeLog:1.2328 Thu May 20 18:13:47 2004 +++ kaffe/ChangeLog Thu May 20 19:08:47 2004 @@ -1,5 +1,18 @@ 2004-05-20 Dalibor Topic <[EMAIL PROTECTED]> + * libraries/javalib/java/lang/Throwable.java: + Resynced with GNU Classpath. + + * libraries/javalib/java/lang/System.java: + (props) Renamed into properties. Made package private. + + 2004-05-20 Mark Wielaard <[EMAIL PROTECTED]> + + * java/lang/Throwable.java (StaticData.nl): Initialize through + directly accessing System.properties.getProperty(). + +2004-05-20 Dalibor Topic <[EMAIL PROTECTED]> + * libraries/javalib/java/io/DeleteFileHelper.java: New file, taken from GNU Classpath. Index: kaffe/libraries/javalib/java/lang/System.java diff -u kaffe/libraries/javalib/java/lang/System.java:1.36 kaffe/libraries/javalib/java/lang/System.java:1.37 --- kaffe/libraries/javalib/java/lang/System.java:1.36 Mon Mar 22 11:24:47 2004 +++ kaffe/libraries/javalib/java/lang/System.java Thu May 20 19:08:51 2004 @@ -26,7 +26,7 @@ final public static InputStream in; final public static PrintStream out; final public static PrintStream err; - private static Properties props; + static Properties properties; private static SecurityManager security; // When trying to debug Java code that gets executed early on during @@ -40,10 +40,10 @@ static { // XXX what are the constraints on the initialization order in here? - props = initProperties(new Properties()); + properties = initProperties(new Properties()); // Initialise the I/O - if (props.getProperty("kaffe.embedded", "false").equals("false")) { + if (properties.getProperty("kaffe.embedded", "false").equals("false")) { in = new BufferedInputStream(new FileInputStream(FileDescriptor.in), 128); out = new PrintStream(new BufferedOutputStream(new FileOutputStream(FileDescriptor.out), 128), true); err = new PrintStream(new BufferedOutputStream(new FileOutputStream(FileDescriptor.err), 128), true); @@ -85,19 +85,19 @@ public static Properties getProperties() { checkPropertiesAccess(); - return props; + return properties; } public static String getProperty(String key) { checkPropertyAccess(key); - return props.getProperty(key); + return properties.getProperty(key); } public static String getProperty(String key, String def) { checkPropertyAccess(key); - return props.getProperty(key, def); + return properties.getProperty(key, def); } public static SecurityManager getSecurityManager() { @@ -110,7 +110,7 @@ native public static int identityHashCode(Object x); -native private static Properties initProperties(Properties props); +native private static Properties initProperties(Properties properties); public static void load(String filename) { Runtime.getRuntime().load(filename, @@ -165,16 +165,16 @@ sm.checkPermission(new PropertyPermission(key, "write")); if (key.length() == 0) throw new IllegalArgumentException("key can't be empty"); - return (String)props.setProperty(key, value); + return (String)properties.setProperty(key, value); } public static void setProperties(Properties prps) { checkPropertiesAccess(); if (prps == null) { - props.clear(); + properties.clear(); return; } - props = prps; + properties = prps; } public static void setSecurityManager(SecurityManager s) { Index: kaffe/libraries/javalib/java/lang/Throwable.java diff -u kaffe/libraries/javalib/java/lang/Throwable.java:1.12 kaffe/libraries/javalib/java/lang/Throwable.java:1.13 --- kaffe/libraries/javalib/java/lang/Throwable.java:1.12 Mon May 17 13:55:03 2004 +++ kaffe/libraries/javalib/java/lang/Throwable.java Thu May 20 19:08:51 2004 @@ -406,7 +406,8 @@ static { - nl = System.getProperty("line.separator"); + // Access package private properties field to prevent Security check. + nl = System.properties.getProperty("line.separator"); } } _______________________________________________ kaffe mailing list [EMAIL PROTECTED] http://kaffe.org/cgi-bin/mailman/listinfo/kaffe