diff --git a/nsock/src/nsock_core.c b/nsock/src/nsock_core.c index e6abfa3bd..41f7b6e02 100644 --- a/nsock/src/nsock_core.c +++ b/nsock/src/nsock_core.c @@ -662,6 +662,7 @@ static int do_actual_read(struct npool *ms, struct nevent *nse) { * sockets, so peerlen is still sizeof(peer) and peer is junk. Instead, * only set this if it's not already set. */ + && !IOD_PROPGET(iod, IOD_STDIN) && (iod->lastproto == IPPROTO_UDP || iod->peerlen == 0) #endif ) {