On Sat, 8 Mar 1997, Walter L. Preuninger II wrote: > I have been reading the gcc-howto and the elf-howto... and have made my > first shared library. My question is: does the code have to be > rewritten/redesigned to take care of any reentrantcy problems? I have a > feeling that globals/statics are bad news. Am I right? > > For Example: > program a calls foo > foo is about to return x to a when > program b calls foo, setting x to something else > > Does this make sense?
Well, if you do not use statics or globals you have no re-entrancy problems. It is also likely that Linux does NOT use shared data segments, as the standard library is a shared library and it contains many globals. This is probably a Good Thing (TM) shared data segments are usually trouble. Jason