From: Guus Sliepen Date: Mon, 23 Aug 2021 16:42:09 +0000 (+0200) Subject: Suppress UBSan warnings in the xoshiro implementation. X-Git-Url: https://tinc-vpn.org/git/browse?a=commitdiff_plain;h=e32d4f3db3f1ed3eebe2e11d57512b60a6c02fa6;p=tinc Suppress UBSan warnings in the xoshiro implementation. Xoshiro relies on the well defined overflow behavior of unsigned integer, but UBSan complains about it unless we force it to ignore it. --- diff --git a/.ci/sanitizers/ignore.txt b/.ci/sanitizers/ignore.txt index 7295aeb1..724f2789 100644 --- a/.ci/sanitizers/ignore.txt +++ b/.ci/sanitizers/ignore.txt @@ -1,2 +1,3 @@ src:ed25519/* src:chacha-poly1305/* +src:xoshiro.c diff --git a/src/autoconnect.c b/src/autoconnect.c index 16093633..9f4abece 100644 --- a/src/autoconnect.c +++ b/src/autoconnect.c @@ -48,7 +48,8 @@ static void make_new_connection() { continue; } - if(r--) { + if(r) { + --r; continue; }