mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-09-27 12:57:53 +00:00
ah6: fix error return code in ah6_input()
[ Upstream commita5ebcbdf34
] Fix to return a negative error code from the error handling case instead of 0, as done elsewhere in this function. Fixes:1da177e4c3
("Linux-2.6.12-rc2") Reported-by: Hulk Robot <hulkci@huawei.com> Signed-off-by: Zhang Changzhong <zhangchangzhong@huawei.com> Link: https://lore.kernel.org/r/1605581105-35295-1-git-send-email-zhangchangzhong@huawei.com Signed-off-by: Jakub Kicinski <kuba@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
ce62d3c7a5
commit
7d6f77b1e0
1 changed files with 2 additions and 1 deletions
|
@ -595,7 +595,8 @@ static int ah6_input(struct xfrm_state *x, struct sk_buff *skb)
|
|||
memcpy(auth_data, ah->auth_data, ahp->icv_trunc_len);
|
||||
memset(ah->auth_data, 0, ahp->icv_trunc_len);
|
||||
|
||||
if (ipv6_clear_mutable_options(ip6h, hdr_len, XFRM_POLICY_IN))
|
||||
err = ipv6_clear_mutable_options(ip6h, hdr_len, XFRM_POLICY_IN);
|
||||
if (err)
|
||||
goto out_free;
|
||||
|
||||
ip6h->priority = 0;
|
||||
|
|
Loading…
Reference in a new issue