From 0b8fd755d8ecdda0389e03dd8f7333d7f8ae6c3d Mon Sep 17 00:00:00 2001 From: Marshall Mohror Date: Mon, 20 Sep 2021 22:28:48 -0500 Subject: [PATCH] Fix `signal_stack_size` for glibc 2.34 `SIGSTKSZ` is now defined as `sysconf(_SC_SIGSTKSZ)` which is not constexpr, and returns a long which throws off the `std::max` template deduction. --- src/dynarmic/backend/x64/exception_handler_posix.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/dynarmic/backend/x64/exception_handler_posix.cpp b/src/dynarmic/backend/x64/exception_handler_posix.cpp index ff01ab60..bdaac0c3 100644 --- a/src/dynarmic/backend/x64/exception_handler_posix.cpp +++ b/src/dynarmic/backend/x64/exception_handler_posix.cpp @@ -64,7 +64,7 @@ private: SigHandler sig_handler; SigHandler::SigHandler() { - constexpr size_t signal_stack_size = std::max(SIGSTKSZ, 2 * 1024 * 1024); + const size_t signal_stack_size = std::max(SIGSTKSZ, 2 * 1024 * 1024); signal_stack_memory = std::malloc(signal_stack_size);