]> git.ipfire.org Git - thirdparty/openvpn.git/commitdiff
Fix clang warning in options.c
authorSteffan Karger <steffan@karger.me>
Wed, 20 Aug 2014 21:00:26 +0000 (23:00 +0200)
committerGert Doering <gert@greenie.muc.de>
Mon, 15 Sep 2014 18:19:56 +0000 (20:19 +0200)
fixed warning: expression which evaluates to zero treated as a
null pointer constant of type 'struct addrinfo *'

Seems to be innocent, but clang is correct that this is strange.
init_tun() expects two pointers, but options_string() tried to
feed it two uint32_t values.

Signed-off-by: Steffan Karger <steffan@karger.me>
Acked-by: David Sommerseth <dazo@users.sourceforge.net>
Message-Id: <1408568426-19601-2-git-send-email-steffan@karger.me>
URL: http://article.gmane.org/gmane.network.openvpn.devel/9004
Signed-off-by: Gert Doering <gert@greenie.muc.de>
src/openvpn/options.c

index f536daa2f6a36068e4fd4aa34d9f7f7fed1d674b..84eb6ed3ac9bfcf68288355304359bc0f8b5bfa5 100644 (file)
@@ -2934,8 +2934,8 @@ options_string (const struct options *o,
                     o->ifconfig_ipv6_local,
                     o->ifconfig_ipv6_netbits,
                     o->ifconfig_ipv6_remote,
-                    (in_addr_t)0,
-                    (in_addr_t)0,
+                    NULL,
+                    NULL,
                     false,
                     NULL);
       if (tt)