Re: [PATCH v2] ipv6/sit: fix ipip6_tunnel_get_prl when memory allocation fails
From: David Ahern
Date: Sun Jun 26 2022 - 13:15:39 EST
On 6/24/22 11:45 PM, zys.zljxml@xxxxxxxxx wrote:
> From: katrinzhou <katrinzhou@xxxxxxxxxxx>
>
> Fix an illegal copy_to_user() attempt when the system fails to
> allocate memory for prl due to a lack of memory.
>
> Addresses-Coverity: ("Unused value")
> Fixes: 300aaeeaab5f ("[IPV6] SIT: Add SIOCGETPRL ioctl to get/dump PRL.")
> Signed-off-by: katrinzhou <katrinzhou@xxxxxxxxxxx>
> ---
>
> Changes in v2:
> - Move the position of label "out"
>
> net/ipv6/sit.c | 7 +++----
> 1 file changed, 3 insertions(+), 4 deletions(-)
>
Reviewed-by: David Ahern <dsahern@xxxxxxxxxx>