diff --git a/libcxx/src/experimental/log_hardening_failure.cpp b/libcxx/src/experimental/log_hardening_failure.cpp index f836c15452249..d385c706c8257 100644 --- a/libcxx/src/experimental/log_hardening_failure.cpp +++ b/libcxx/src/experimental/log_hardening_failure.cpp @@ -18,7 +18,9 @@ _LIBCPP_BEGIN_NAMESPACE_STD void __log_hardening_failure(const char* message) noexcept { // Always log the message to `stderr` in case the platform-specific system calls fail. +#ifndef __Fuchsia__ // `fputs` is not available on Fuchsia. std::fputs(message, stderr); +#endif #if defined(__BIONIC__) // Show error in logcat. The latter two arguments are ignored on Android.