ah: Correctly pass error codes in ahash output callback.

The AH4/6 ahash output callbacks pass nexthdr to xfrm_output_resume
instead of the error code.  This appears to be a copy+paste error from
the input case, where nexthdr is expected.  This causes the driver to
continuously add AH headers to the datagram until either an allocation
fails and the packet is dropped or the ahash driver hits a synchronous
fallback and the resulting monstrosity is transmitted.

Correct this issue by simply passing the error code unadulterated.

Signed-off-by: Nick Bowler <nbowler@elliptictech.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
这个提交包含在:
Nick Bowler
2011-11-08 12:12:44 +00:00
提交者 David S. Miller
父节点 fecc735194
当前提交 069294e813
修改 2 个文件,包含 0 行新增4 行删除

查看文件

@@ -324,8 +324,6 @@ static void ah6_output_done(struct crypto_async_request *base, int err)
#endif
}
err = ah->nexthdr;
kfree(AH_SKB_CB(skb)->tmp);
xfrm_output_resume(skb, err);
}