[ovs-dev] [PATCH] datapath: Fix uninitializaed variable with GRE GSO.
Jesse Gross
jesse at nicira.com
Fri Jun 21 23:11:27 UTC 2013
If a packet is neither GSO nor CHECKSUM_PARTIAL then the
GRE GSO compatibility code can use an uninitialized IP ID.
CC: Pravin Shelar <pshelar at nicira.com>
Reported-by: Joe Stringer <joe at wand.net.nz>
Signed-off-by: Jesse Gross <jesse at nicira.com>
---
datapath/linux/compat/gso.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/datapath/linux/compat/gso.c b/datapath/linux/compat/gso.c
index 7379a57..3cadde9 100644
--- a/datapath/linux/compat/gso.c
+++ b/datapath/linux/compat/gso.c
@@ -103,7 +103,7 @@ free:
int rpl_ip_local_out(struct sk_buff *skb)
{
int ret = NETDEV_TX_OK;
- int id;
+ int id = -1;
if (skb_is_gso(skb)) {
struct iphdr *iph;
@@ -119,7 +119,6 @@ int rpl_ip_local_out(struct sk_buff *skb)
err = skb_checksum_help(skb);
if (unlikely(err))
return 0;
- id = -1;
}
while (skb) {
--
1.8.1.2
More information about the dev
mailing list