Re: processes stuck in skb_recv_datagram

Adam D. Bradley (artdodge@cs.bu.edu)
Sat, 24 Jul 1999 17:57:02 -0400 (EDT)


On Fri, 23 Jul 1999, I wrote:

> Rob Riggs wrote:
> > Multiple threads calling gethostbyname_r() (and using DNS
> > to resolve) ends up with threads stuck in skb_recv_datagram.
>
> [snip]
>
> All the userspace code appears correct;

Yuck! I take it back!

The res_send.c code in glibc2.1.1 (and all prior versions, inc 2.0.x)
resolv library looks fundamentally broken for any threaded environments.
There are gaping, wide-open race conditions.

The kernel is fine (I've hammered it all sorts of ways and can't produce
the same lockup with poll/recvmesg or select/recvmesg), it looks like
libresolv is the problem.

Adam

--
Your lives aren't small, but    \ Adam Davenport Bradley,  Grad Student
you're living them in a small    \ Boston University   Computer Science
way. Live openly and expansively! \ artdodge@cs.bu.edu  353-8921/MCS211
II Cor 6:12-13 (The Message)  <><  \ http://www.netwinder.org/~artdodge

Hi! I'm a signature virus! Copy me into your signature so I can spread!!

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/