diff options
author | Jason A. Donenfeld <Jason@zx2c4.com> | 2018-09-19 04:06:27 +0200 |
---|---|---|
committer | Jason A. Donenfeld <Jason@zx2c4.com> | 2018-09-20 02:07:56 +0200 |
commit | 470a0c58d85d451cadae663c3a1d8c8c2538ef31 (patch) | |
tree | 43996382f2f2370906bfab6ede75aade0a8caca1 /src/allowedips.c | |
parent | chacha20: prefer crypto_xor_cpy to avoid memmove (diff) | |
download | wireguard-monolithic-historical-470a0c58d85d451cadae663c3a1d8c8c2538ef31.tar.xz wireguard-monolithic-historical-470a0c58d85d451cadae663c3a1d8c8c2538ef31.zip |
allowedips: change from BUG_ON to WARN_ON
This is never going to hit anyway, and if it does, it's a development
problem that will be caught with the selftests anyway. So don't make
Andrew Lunn upset, and just change it to a WARN_ON.
Suggested-by: Andrew Lunn <andrew@lunn.ch>
Diffstat (limited to 'src/allowedips.c')
-rw-r--r-- | src/allowedips.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/allowedips.c b/src/allowedips.c index 5681c2a..7202469 100644 --- a/src/allowedips.c +++ b/src/allowedips.c @@ -50,7 +50,7 @@ static void node_free_rcu(struct rcu_head *rcu) #define push_rcu(stack, p, len) ({ \ if (rcu_access_pointer(p)) { \ - BUG_ON(len >= 128); \ + WARN_ON(len >= 128); \ stack[len++] = rcu_dereference_raw(p); \ } \ true; \ @@ -109,7 +109,7 @@ walk_by_peer(struct allowedips_node __rcu *top, u8 bits, #define ref(p) rcu_access_pointer(p) #define deref(p) rcu_dereference_protected(*p, lockdep_is_held(lock)) #define push(p) ({ \ - BUG_ON(len >= 128); \ + WARN_ON(len >= 128); \ stack[len++] = p; \ }) static void walk_remove_by_peer(struct allowedips_node __rcu **top, |