From 0e494a3345f1c635d5979571dd55a1c663992d97 Mon Sep 17 00:00:00 2001 From: David Rubin Date: Thu, 8 Oct 2026 10:23:58 -0500 Subject: [PATCH] Compilation: turn off ubsan sanitization of functions in trap mode --- src/Compilation.zig | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/Compilation.zig b/src/Compilation.zig index 98de2b172c03bafc6181d2a9dd8e3e64c726b1b7..553ee10fbc0939264fc9e772fe069671de6ca6f6 100644 --- a/src/Compilation.zig +++ b/src/Compilation.zig @@ -6546,6 +6546,9 @@ fn addCommonCCArgs( .off => {}, .trap => { try argv.append("-fsanitize-trap=undefined"); + + // Same reasoning as below. + try argv.append("-fno-sanitize=function"); }, .full => { // This check requires implementing the Itanium C++ ABI. -- 2.54.0