Skip to content
Commit 7e58c560 authored by Aska Wu's avatar Aska Wu Committed by Jukka Rissanen
Browse files

net: sockets: Fix net pkt leak



If net_context_recv() returns a error, net pkt will not be released. For
example, net_context_recv() returns -EBADF because the TCP connection is
closed by the peer.

Handle the return value instead of using SET_ERRNO().

Signed-off-by: default avatarAska Wu <aska.wu@linaro.org>
parent 486e1568
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment