]> git.ipfire.org Git - thirdparty/openvpn.git/commit
Use proper print format/casting when converting msg_channel handle
authorArne Schwabe <arne@rfc2549.org>
Tue, 14 Feb 2023 13:43:23 +0000 (14:43 +0100)
committerGert Doering <gert@greenie.muc.de>
Wed, 1 Mar 2023 13:25:18 +0000 (14:25 +0100)
commit9c52e0c610ef1229561c2d038ca41fe2cbefe8da
treee6a8b002d20dc2f767c1d10bbc2f0297d6801ba8
parentb8eddda8524bf6f164361667bfce6bbb3fac846b
Use proper print format/casting when converting msg_channel handle

The current casting triggers a warning on 32bit:

    init.c:1842:66: error: cast from pointer to integer of different size
[-Werror=pointer-to-int-cast]

Use the proper printf format specifier for printing a pointer avoiding
the cast alltogether.

In options.c use a cast to intptr_t before converting to a handle to
avoid having to ifdef atoll/atol for 32/64 bit.

Signed-off-by: Arne Schwabe <arne@rfc2549.org>
Acked-by: Lev Stipakov <lstipakov@gmail.com>
Message-Id: <20230214134323.1033590-1-arne@rfc2549.org>
URL: https://www.mail-archive.com/openvpn-devel@lists.sourceforge.net/msg26255.html
Signed-off-by: Gert Doering <gert@greenie.muc.de>
src/openvpn/init.c
src/openvpn/options.c