]> git.ipfire.org Git - thirdparty/openvpn.git/commit
use boolean '||' to join two bools, not bitwise '|'
authorGert Doering <gert@greenie.muc.de>
Tue, 4 Oct 2022 14:51:42 +0000 (16:51 +0200)
committerGert Doering <gert@greenie.muc.de>
Tue, 4 Oct 2022 16:40:30 +0000 (18:40 +0200)
commitfacb6fffb35f51e67eefaab8ba357b676b3c6328
tree4124da90fc3bd6ef6719d91f348a748753e6fc05
parentd4c34b5246e58f83ee8b87249173521a28de6993
use boolean '||' to join two bools, not bitwise '|'

FreeBSD 14 clang complains about this:

init.c:3530:13: warning: use of bitwise '|' with boolean operands
[-Wbitwise-instead-of-logical]
            platform_group_get(c->options.groupname,
&c0->platform_state_group)

^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
init.c:3530:13: note: cast one or both operands to int to silence this
warning
1 warning generated.

.. so do what it wants us to do.

Signed-off-by: Gert Doering <gert@greenie.muc.de>
Acked-by: Antonio Quartulli <a@unstable.cc>
Message-Id: <20221004145142.19091-1-gert@greenie.muc.de>
URL: https://www.mail-archive.com/openvpn-devel@lists.sourceforge.net/msg25333.html
Signed-off-by: Gert Doering <gert@greenie.muc.de>
src/openvpn/init.c