Attention is currently required from: osmith, laforge, fixeria.
2 comments:
File src/osmo_ss7.c:
Patch Set #1, Line 1951: rc = 0;
What if rc == -EAGAIN, do you want it to be set to 0? (probably, but just to be sure)
Yes, this is fine, we just clear any error code (like -EBADF) which may trigger stuff in the callback caller. It's totally fine returning 0 instead of EAGAIN here, since we already did whatever we had to do (and the READ flag is still set so poll will trigger again if the kernel finds out the socket has somethig else for us).
Patch Set #1, Line 1954: if (rc < 0) {
why not if (rc <= 0) {? […]
I prefer keeping the 2 scenarios separate, even if we end up doing the same right now. In the future we may want to check for specific errors in this path.
To view, visit change 34089. To unsubscribe, or for help writing mail filters, visit settings.