[build] Fix warning (#4177)
[mono.git] / mono / mini / mini-exceptions.c
index 2f25bbda818cb4c52e0fd143d8100003ca5489c6..f4c1d974efa41777c8f48886e4e67b022e0f6b2c 100644 (file)
@@ -2535,7 +2535,7 @@ mono_handle_native_crash (const char *signal, void *ctx, MONO_SIG_HANDLER_INFO_T
 #if defined(PLATFORM_ANDROID)
                /* SYS_fork is defined to be __NR_fork which is not defined in some ndk versions */
                g_assert_not_reached ();
-#elif defined(SYS_fork)
+#elif !defined(PLATFORM_MACOSX) && defined(SYS_fork)
                pid = (pid_t) syscall (SYS_fork);
 #elif defined(PLATFORM_MACOSX) && HAVE_FORK
                pid = (pid_t) fork ();
@@ -2571,8 +2571,9 @@ mono_handle_native_crash (const char *signal, void *ctx, MONO_SIG_HANDLER_INFO_T
         * this has changed on later versions of Android.  Also, we don't want to
         * set this on start-up as DUMPABLE has security implications. */
        prctl (PR_SET_DUMPABLE, 1);
+
+       mono_runtime_printf_err ("\nNo native Android stacktrace (see debuggerd output).\n");
 #endif
-       mono_exception_native_unwind (ctx, info);
 #endif
 
        /*