Skip to contentSkip to conversation

kill ip_conntrack_tftp compile warning

PATCH New Filip Sneppe (Cronos) 1 participant 1 message Jun 29, 2003

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 kill ip_conntrack_tftp compile warning

Hi,

Attached trivial patch kills the following compiler warning on 2.4.22-pre (probably 2.4.21 too). 2.5 already has the fix.

gcc -D__KERNEL__ -I/home/sneppef/kernel/linux-2.4.22-pre2-orig/include -Wall -Wstrict-prototypes -Wno-trigraphs -O2 -fno-strict-aliasing -fno-common -fomit-frame-pointer -pipe -mpreferred-stack-boundary=2 -march=k6 -DMODULE -DMODVERSIONS -include /home/sneppef/kernel/linux-2.4.22-pre2-orig/include/linux/modversions.h -nostdinc -iwithprefix include -DKBUILD_BASENAME=ip_nat_tftp -c -o ip_nat_tftp.o ip_nat_tftp.c
ip_nat_tftp.c: In function `init':
ip_nat_tftp.c:156: warning: `ret' might be used uninitialized in this function

Regards,
Filip

net/ipv4/netfilter/ip_nat_tftp.c 2003-06-29 05:16:35.000000000 +0200 renamed from net/ipv4/netfilter/ip_nat_tftp.c 2003-06-13 16:51:39.000000000 +0200 +1 -1
diff -urN -X dontdiff linux-2.4.22-pre2-orig/net/ipv4/netfilter/ip_nat_tftp.c linux-2.4.22-pre2/net/ipv4/netfilter/ip_nat_tftp.c
@@ -153,7 +153,7 @@
 
 static int __init init(void)
 {
-	int i, ret;
+	int i, ret = 0;
 	char *tmpname;
 
 	if (!ports[0])