Remove SIGTRAP from block list for HWASan build 17/265917/3 accepted/tizen_7.0_base_hotfix accepted/tizen_7.0_base_tool_hotfix tizen_7.0_base_hotfix accepted/tizen/7.0/base/hotfix/20230714.003924 accepted/tizen/7.0/base/tool/20221028.120335 accepted/tizen/7.0/base/tool/hotfix/20221115.084354 accepted/tizen/base/tool/20211230.001929 submit/tizen_7.0_base/20221028.201301 submit/tizen_7.0_base_hotfix/20221115.161701 submit/tizen_base/20211220.072804 tizen_7.0_m2_release
authorAndrey Kazmin <a.kazmin@partner.samsung.com>
Thu, 8 Jul 2021 10:59:25 +0000 (13:59 +0300)
committerAndrey Kazmin <a.kazmin@partner.samsung.com>
Thu, 9 Dec 2021 08:57:53 +0000 (11:57 +0300)
HWASan uses SIGTRAP to report an error. Do not block it.

Change-Id: I5c89ae4930a3cb2edddbc3034d430356557cddba
Signed-off-by: Andrey Kazmin <a.kazmin@partner.samsung.com>
packaging/rpm.spec
rpmio/rpmsq.c

index 9bb1322..8a4b3c7 100644 (file)
@@ -155,6 +155,10 @@ export LDFLAGS="${LDFLAGS} -pie -Wl,-Bsymbolic-functions -ffunction-sections"
 export CFLAGS="-g -O0 -fno-strict-aliasing -ffunction-sections"
 %endif
 
+%{?hwasan_build:
+export CPPFLAGS="$CPPFLAGS -DHWASAN_BUILD"
+}
+
 %reconfigure \
     --disable-dependency-tracking \
     --with-lua \
index d157514..1bbdd0a 100644 (file)
@@ -186,6 +186,9 @@ int rpmsqBlock(int op)
            sigdelset(&newMask, SIGILL);
            sigdelset(&newMask, SIGSEGV);
            sigdelset(&newMask, SIGTSTP);
+#ifdef HWASAN_BUILD
+           sigdelset(&newMask, SIGTRAP);
+#endif
            ret = pthread_sigmask(SIG_BLOCK, &newMask, &oldMask);
        }
     } else if (op == SIG_UNBLOCK) {