[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20151116.170738.762655257161553595.davem@davemloft.net>
Date: Mon, 16 Nov 2015 17:07:38 -0500 (EST)
From: David Miller <davem@...emloft.net>
To: sd@...asysnail.net
Cc: netdev@...r.kernel.org, jiri@...nulli.us, kaber@...sh.net
Subject: Re: [PATCH net] macvlan: fix leak in macvlan_handle_frame
From: Sabrina Dubroca <sd@...asysnail.net>
Date: Mon, 16 Nov 2015 22:54:20 +0100
> Reset pskb in macvlan_handle_frame in case skb_share_check returned a
> clone.
>
> Fixes: 8a4eb5734e8d ("net: introduce rx_handler results and logic around that")
> Signed-off-by: Sabrina Dubroca <sd@...asysnail.net>
Thanks for finding all of these bugs which seem to have the same
signature.
I always find pass by reference handling of SKBs to be extremely error
prone, and it's a very inefficient calling convention anyways.
I wondered if we could do better with the interface for rx_handler,
for example returning an error-pointer for the 'new_skb', but nothing
I came up with could provide the same semantics we have now.
Sigh...
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists