natRuntime.cc (insertSystemProperties): Added GCJ runtime property "gnu.gcj.progname...
authorRanjit Mathew <rmathew@hotmail.com>
Sun, 20 Oct 2002 23:47:43 +0000 (23:47 +0000)
committerTom Tromey <tromey@gcc.gnu.org>
Sun, 20 Oct 2002 23:47:43 +0000 (23:47 +0000)
2002-10-19  Ranjit Mathew <rmathew@hotmail.com>

* java/lang/natRuntime.cc (insertSystemProperties): Added GCJ
runtime property "gnu.gcj.progname" containing the name used to
invoke the current Java program (similar to argv[0] for C
programs).

From-SVN: r58343

libjava/ChangeLog
libjava/java/lang/natRuntime.cc

index 16f50b409f338bfdba1fcdf130ba5016da28dd9a..982cc64eaa1f5e0869348d4aee9da7f3170af820 100644 (file)
@@ -1,3 +1,10 @@
+2002-10-19  Ranjit Mathew <rmathew@hotmail.com>
+
+       * java/lang/natRuntime.cc (insertSystemProperties): Added GCJ
+       runtime property "gnu.gcj.progname" containing the name used to
+       invoke the current Java program (similar to argv[0] for C
+       programs).
+
 2002-10-15  Tom Tromey  <tromey@redhat.com>
 
        Fix for PR libgcj/8234:
index 18ec2321475e32eda60ee52b1064c6201942081a..d0a64e7bb1d4955433bd7b8137e0f404d2f4320a 100644 (file)
@@ -533,6 +533,9 @@ java::lang::Runtime::insertSystemProperties (java::util::Properties *newprops)
                      sb->toString ());
     }
 
+  // The name used to invoke this process (argv[0] in C).
+  SET ("gnu.gcj.progname", _Jv_ThisExecutable());
+
   // Allow platform specific settings and overrides.
   _Jv_platform_initProperties (newprops);
 }