summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorOneric <oneric@oneric.stub>2022-11-09 01:19:58 +0100
committerOneric <oneric@oneric.stub>2022-11-10 21:19:37 +0100
commit44beae2ae57790ba592b8f0d20c0b51006f6b7c7 (patch)
tree5789b8e8125ae6d913b622d48b475baaeb5e1bbf
parent52783a46c0f56ccfb66795667f069a1d2993cfcf (diff)
downloadlibass-44beae2ae57790ba592b8f0d20c0b51006f6b7c7.tar.bz2
libass-44beae2ae57790ba592b8f0d20c0b51006f6b7c7.tar.xz
ci/gha: reenable sanitisers for 64-bit Windows
It turns out, the undefined behaviour we detected was not in our own code, but in the inline isnan() function from MinGW-w64's headers. A patch has been submitted to and merged by MinGW-w64: https://sourceforge.net/p/mingw-w64/mailman/mingw-w64-public/thread/20221109020507.1704-1-chortos@inbox.lv/ Until a version containing the fix is available in MSYS2, we can avoid problematic inlines by defining __CRT__NO_INLINE. Closes: https://github.com/libass/libass/issues/639
-rw-r--r--.github/workflows/ghci.yml11
1 files changed, 7 insertions, 4 deletions
diff --git a/.github/workflows/ghci.yml b/.github/workflows/ghci.yml
index 7383ab1..024aad3 100644
--- a/.github/workflows/ghci.yml
+++ b/.github/workflows/ghci.yml
@@ -152,8 +152,12 @@ jobs:
# but when SIGILL'ing the lib is not needed
# ASAN: Not supported with musl and in Windows
case "${{ matrix.docker_image || matrix.os }}" in
- alpine*|windows-*)
+ alpine*)
flags="$uflags -fsanitize-undefined-trap-on-error" ;;
+ windows-*)
+ # TEMPORARY: MinGW's headers have problematic code in isnan's inline version
+ # triggering UBSAN. Until the fix is available in MSYS2, avoid inlines.
+ flags="$uflags -fsanitize-undefined-trap-on-error -D__CRT__NO_INLINE=1" ;;
*)
flags="$aflags $uflags" ;;
esac
@@ -162,12 +166,11 @@ jobs:
flags="$flags -fno-sanitize-recover=all"
fi
- if [ "${{ matrix.cc }}" = "tcc" ] || [ "${{ matrix.skip_tests }}" = "yes" ] \
- || [ "${{ matrix.api }}" = "app" ] ; then
- # FIXME: For Windows UWP, UBSAN triggers on regression/karaoke/357-k-and-kf-desynced.ass
+ if [ "${{ matrix.cc }}" = "tcc" ] || [ "${{ matrix.skip_tests }}" = "yes" ] ; then
flags=""
fi
+
echo "SANFLAGS=$flags"
echo "::set-output name=flags::${flags}"