Skip to contentSkip to conversation

unused variable in skb_ip_make_writable()

DISCUSSION Yasuyuki Kozakai 1 participant 2 messages Jun 24, 2004 netfilter

lore
Share & tools
lore
#0 lore raw

Hi, iplen in skb_ip_make_writable() is not used.

please apply this patch.

Regards,

-----------------------------------------------------------------
Yasuyuki KOZAKAI @ USAGI Project <[email protected]>

#1 lore raw

Sorry, I misstook...

From: Yasuyuki Kozakai <[email protected]>
Date: Fri, 25 Jun 2004 00:09:51 +0900 (JST)

Quoted 9 lines

Hi, iplen in skb_ip_make_writable() is not used.

please apply this patch.

Regards,

-----------------------------------------------------------------
Yasuyuki KOZAKAI @ USAGI Project <[email protected]>

Index: netfilter.c
===================================================================
RCS file: /cvsroot/usagi/usagi/kernel/linux26/net/core/netfilter.c,v retrieving revision 1.1.1.23

netfilter.c +0 -3
diff -u -r1.1.1.23 netfilter.c
@@ -677,7 +677,6 @@
 int skb_ip_make_writable(struct sk_buff **pskb, unsigned int writable_len)
 {
 	struct sk_buff *nskb;
-	unsigned int iplen;
 
 	if (writable_len > (*pskb)->len)
 		return 0;
@@ -690,8 +689,6 @@
 	if (writable_len <= (*pskb)->nh.iph->ihl*4)
 		return 1;
 
-	iplen = writable_len - (*pskb)->nh.iph->ihl*4;
-
 	/* DaveM says protocol headers are also modifiable. */
 	switch ((*pskb)->nh.iph->protocol) {
 	case IPPROTO_TCP: {