Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
posix: sockets: address was not set in recvfrom
The address is an optional parameter of recvfrom. If it is not null, recvfrom must store the address of the sender. However this was only allowed if res was equal to 0, which is wrong since res contains the number of bytes received or -1. This commit ensures that the address is set only if no previous errors happened before. Signed-off-by: Francois Berder <francois.berder@imgtec.com>
- Loading branch information