[RFC] Improve libnl non-blocking behaviour

Holger Eitzenberger holger at eitzenberger.org
Tue Apr 2 06:13:04 EDT 2013


> I can't see how somebody can rely on it returning 0 though without an
> obvious risk for a infinite loop. Therefore I commited the following
> to the tree:

Good point.

> @@ -627,11 +627,6 @@ retry:
>                         NL_DBG(3, "recvmsg() returned EINTR, retrying\n");
>                         goto retry;
>                 }
> -               if (errno == EAGAIN || errno == EWOULDBLOCK) {
> -                       NL_DBG(3, "recvmsg() returned EAGAIN||EWOULDBLOCK, aborting\n");
> -                       retval = 0;
> -                       goto abort;
> -               }
>                 retval = -nl_syserr2nlerr(errno);
>                 goto abort;
>         }

Thanks!  This looks better than my approach.

 /Holger




More information about the libnl mailing list