From: Doug MacEachern Date: Tue, 5 May 2009 07:37:00 +0000 (+0200) Subject: iptables plugin: Initialize ip_version. X-Git-Tag: collectd-4.7.0~23 X-Git-Url: https://git.verplant.org/?a=commitdiff_plain;h=ce545d5c78ac284081d914afdccc8dd209f41606;p=collectd.git iptables plugin: Initialize ip_version. iptables.c: In function 'iptables_config': iptables.c:99: warning: 'ip_version' is used uninitialized in this function Signed-off-by: Florian Forster --- diff --git a/src/iptables.c b/src/iptables.c index fb887da6..3062a0cd 100644 --- a/src/iptables.c +++ b/src/iptables.c @@ -89,7 +89,7 @@ static int chain_num = 0; static int iptables_config (const char *key, const char *value) { /* int ip_value; */ - protocol_version_t ip_version; + protocol_version_t ip_version = 0; if (strcasecmp (key, "Chain") == 0) ip_version = IPV4;