OSDN Git Service

* crtstuff.c (__do_global_ctors_aux): Do not call __cxa_finalize
authormmitchel <mmitchel@138bc75d-0d04-0410-961f-82ee72b054a4>
Sun, 19 Dec 1999 05:36:13 +0000 (05:36 +0000)
committermmitchel <mmitchel@138bc75d-0d04-0410-961f-82ee72b054a4>
Sun, 19 Dec 1999 05:36:13 +0000 (05:36 +0000)
in a main program.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@31023 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/ChangeLog
gcc/crtstuff.c

index 54eead1..3c92b7e 100644 (file)
@@ -1,3 +1,8 @@
+1999-12-18  Mark Mitchell  <mark@codesourcery.com>
+
+       * crtstuff.c (__do_global_ctors_aux): Do not call __cxa_finalize
+       in a main program.
+
 Sat Dec 18 20:42:43 1999  Richard Henderson  <rth@cygnus.com>
 
        * cccp.c (main): Define __STDC_VERSION__ as necessary.
index 53dae7c..c0a6ae0 100644 (file)
@@ -172,8 +172,10 @@ __do_global_dtors_aux (void)
   if (completed)
     return;
 
-  if (__dso_handle && __cxa_finalize)
+#ifdef CRTSTUFFS_O
+  if (__cxa_finalize)
     __cxa_finalize (__dso_handle);
+#endif
 
   while (*p)
     {