]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
prims.cc (_Jv_RunMain): Set the name of this executable.
authorAndrew Haley <aph@cygnus.com>
Tue, 18 Jan 2000 14:37:34 +0000 (14:37 +0000)
committerAndrew Haley <aph@gcc.gnu.org>
Tue, 18 Jan 2000 14:37:34 +0000 (14:37 +0000)
2000-01-17  Andrew Haley  <aph@cygnus.com>

* prims.cc (_Jv_RunMain): Set the name of this executable.

From-SVN: r31486

libjava/ChangeLog
libjava/prims.cc

index 5eaf47843cd414999b10fbbb6f7c6cd6b034b9cf..ce4526f36b20044987e2d6f4fccc4a4e8109f2a2 100644 (file)
@@ -1,3 +1,7 @@
+2000-01-17  Andrew Haley  <aph@cygnus.com>
+
+       * prims.cc (_Jv_RunMain): Set the name of this executable.
+
 2000-01-17  Tom Tromey  <tromey@cygnus.com>
 
        * java/lang/natThrowable.cc (fillInStackTrace): Return `this' even
index 6e11d8045bdb9aa352008ec76505a715dd8a45df..f1ff2132844f9d974891394ea0f3e62edd7f5a71 100644 (file)
@@ -863,6 +863,12 @@ _Jv_RunMain (const char *class_name, int argc, const char **argv)
 
   main_init ();
 
+#ifdef HAVE_PROC_SELF_EXE
+  char exec_name[20];
+  sprintf (exec_name, "/proc/%d/exe", getpid ());
+  _Jv_ThisExecutable (exec_name);
+#endif
+
   arg_vec = JvConvertArgv (argc - 1, argv + 1);
   main_group = new java::lang::ThreadGroup (23);
   main_thread = new java::lang::FirstThread (main_group,