On Thu, Dec 05, 2002 at 11:30:00PM +1300, Craig McGeachie wrote: >On 5 Dec 2002 at 23:22, Craig McGeachie wrote: >> - declare a subclass of per_thread into perthread.h for >> whatever data netdb.cc uses. >> - declare a single global instance of this subclass in perthread.h >> - define the global instance in dcrt0.cc >> - add it to threadstuff in dcrt0.cc > >Actually, messing about with dcrt0.cc and perthread.h makes me a little >uncomfortable. The per_thread objects only seem to need to be in there >if fork.cc needs to check for clear_on_fork. Could I just put >everything into netdb.cc?
Yes. You're right. In fact, it hit me this morning as I was waking up that I might have steered you wrong here. There are other per-thread entities in cygwin that don't use the perthread interface. So, rolling your own is fine. cgf
