net/socket/getpeername: Fixed warning in DEBUG code.

This commit is contained in:
David Sidrane 2019-08-07 07:53:56 -06:00 committed by Gregory Nutt
parent 06f693965c
commit 1e90dd9284

View file

@ -105,7 +105,7 @@ int psock_getpeername(FAR struct socket *psock, FAR struct sockaddr *addr, FAR s
*/
#ifdef CONFIG_DEBUG_FEATURES
if (addr == NULL || addrlen <= 0)
if (addr == NULL || *addrlen <= 0)
{
return -EINVAL;
}