aboutsummaryrefslogtreecommitdiffstats
path: root/.drone.yml
diff options
context:
space:
mode:
authorAnton Yuzhaninov <citrin+git@citrin.ru>2018-11-13 19:41:52 -0500
committerAnton Yuzhaninov <citrin+git@citrin.ru>2018-11-13 22:11:56 -0500
commit53947bd6bc504e1450b11f6fc345d409bf3e9a86 (patch)
tree9368c820595b5eb27f980df6cffd33fa32f83f7a /.drone.yml
parent5496ce20f0b43700809ac0906a72a168398e866b (diff)
downloadrspamd-53947bd6bc504e1450b11f6fc345d409bf3e9a86.tar.gz
rspamd-53947bd6bc504e1450b11f6fc345d409bf3e9a86.zip
Use clang sanitizers
Diffstat (limited to '.drone.yml')
-rw-r--r--.drone.yml9
1 files changed, 8 insertions, 1 deletions
diff --git a/.drone.yml b/.drone.yml
index da1386e26..8bdbc77e2 100644
--- a/.drone.yml
+++ b/.drone.yml
@@ -38,6 +38,8 @@ pipeline:
- test "$(id -un)" = nobody
- cd /rspamd/fedora/build
- export LDFLAGS='-fuse-ld=lld'
+ - export CFLAGS='-fsanitize=address,undefined,implicit-integer-truncation'
+ - export ASAN_OPTIONS=detect_leaks=0
- >
cmake
-DENABLE_CLANG_PLUGIN=ON
@@ -112,7 +114,11 @@ pipeline:
group: tests
commands:
- test "$(id -un)" = nobody
- - ulimit -c unlimited
+ # Asan reserves 20Tb of virtual memory, limit core size to 2 Gb to avoid writing huge core
+ - ulimit -c 2097152
+ # disable leak sanitizer: too many leaks detected, most of them probably FP
+ - export ASAN_OPTIONS="detect_leaks=0:print_stacktrace=1:disable_coredump=0"
+ - export UBSAN_OPTIONS="print_stacktrace=1:log_path=/tmp/ubsan"
- cd /rspamd/fedora/build/test
- set +e
- ./rspamd-test -p /rspamd/lua; EXIT_CODE=$?
@@ -123,6 +129,7 @@ pipeline:
if [ $EXIT_CODE -gt 128 ]; then
gdb --batch -ex 'bt' -c /var/tmp/*.rspamd-test.core ./rspamd-test;
fi
+ - cat /tmp/ubsan.*
- exit $EXIT_CODE
functional: