OSDN Git Service

* decl.c (register_dtor_fn): Pass the address of dso_handle, not
authormmitchel <mmitchel@138bc75d-0d04-0410-961f-82ee72b054a4>
Tue, 16 Apr 2002 03:17:57 +0000 (03:17 +0000)
committermmitchel <mmitchel@138bc75d-0d04-0410-961f-82ee72b054a4>
Tue, 16 Apr 2002 03:17:57 +0000 (03:17 +0000)
dso_handle itself, to __cxa_atexit.

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

gcc/cp/ChangeLog
gcc/cp/decl.c

index 2863b77..d19ea37 100644 (file)
@@ -1,3 +1,8 @@
+2002-04-15  Mark Mitchell  <mark@codesourcery.com>
+
+       * decl.c (register_dtor_fn): Pass the address of dso_handle, not
+       dso_handle itself, to __cxa_atexit.
+
 2002-04-15  Gabriel Dos Reis  <gdr@merlin.codesourcery.com>
 
        * error.c (cxx_print_error_function): Adjust call to macros.
index 721cd63..04c9799 100644 (file)
@@ -8608,7 +8608,9 @@ register_dtor_fn (decl)
   cleanup = build_unary_op (ADDR_EXPR, cleanup, 0);
   if (flag_use_cxa_atexit)
     {
-      args = tree_cons (NULL_TREE, get_dso_handle_node (), NULL_TREE);
+      args = tree_cons (NULL_TREE, 
+                       build_unary_op (ADDR_EXPR, get_dso_handle_node (), 0),
+                       NULL_TREE);
       args = tree_cons (NULL_TREE, null_pointer_node, args);
       args = tree_cons (NULL_TREE, cleanup, args);
     }