Subj : Re: a thread question To : comp.programming.threads From : Loic Domaigne Date : Fri May 13 2005 12:11 am Hi David, >>>can I use it at the child thread? >> >>To be visible from every threads, the variable must be global. > > > Nope. All variables are visible to all threads. Sure. But if count is declared in the main body, then the compiler shall complain that count isn't defined if you refer to the count variable in the thread (of course, you could always refer to count via its address). For the situation we're speaking of, I prefer to use a global variable. Cheers, Loic. .