From: Steffen Klassert Date: Mon, 12 Jan 2015 12:38:49 +0000 (+0100) Subject: xfrm: Fix local error reporting crash with interfamily tunnels X-Git-Tag: omap-for-v4.1/fixes-rc1~306^2~9^2~1 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=044a832a7779c0638bea2d0fea901c055b995f4a;p=pandora-kernel.git xfrm: Fix local error reporting crash with interfamily tunnels We set the outer mode protocol too early. As a result, the local error handler might dispatch to the wrong address family and report the error to a wrong socket type. We fix this by setting the outer protocol to the skb after we accessed the inner mode for the last time, right before we do the atcual encapsulation where we switch finally to the outer mode. Reported-by: Chris Ruehl Tested-by: Chris Ruehl Signed-off-by: Steffen Klassert --- Reading git-diff-tree failed