summary refs log tree commit diff
path: root/stdlib
diff options
context:
space:
mode:
Diffstat (limited to 'stdlib')
-rw-r--r--stdlib/cxa_finalize.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/stdlib/cxa_finalize.c b/stdlib/cxa_finalize.c
index 7d7b09b3cc..75ea4022fb 100644
--- a/stdlib/cxa_finalize.c
+++ b/stdlib/cxa_finalize.c
@@ -18,7 +18,7 @@
 #include <assert.h>
 #include <stdlib.h>
 #include "exit.h"
-#include <fork.h>
+#include <register-atfork.h>
 #include <sysdep.h>
 #include <stdint.h>
 
@@ -102,9 +102,7 @@ __cxa_finalize (void *d)
 
   /* Remove the registered fork handlers.  We do not have to
      unregister anything if the program is going to terminate anyway.  */
-#ifdef UNREGISTER_ATFORK
   if (d != NULL)
     UNREGISTER_ATFORK (d);
-#endif
   __libc_lock_unlock (__exit_funcs_lock);
 }