Thread (3 messages) 3 messages, 3 authors, 2013-10-01

Re: [PATCH] ipv6: gre: correct calculation of max_headroom

From: Eric Dumazet <hidden>
Date: 2013-09-29 08:05:03

On Sun, 2013-09-29 at 05:40 +0200, Hannes Frederic Sowa wrote:
gre_hlen already accounts for sizeof(struct ipv6_hdr) + gre header,
so initialize max_headroom to zero. Otherwise the

	if (encap_limit >= 0) {
		max_headroom += 8;
		mtu -= 8;
	}

increments an uninitialized variable before max_headroom was reset.

Found with coverity: 728539

Cc: Dmitry Kozlov <redacted>
Signed-off-by: Hannes Frederic Sowa <redacted>
---
Acked-by: Eric Dumazet <edumazet@google.com>
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help