Re: reinitialization of global varriables in .sbss section across calls on MIPS
Martin Husemann <[email protected]>
| Newsgroups | gmane.os.netbsd.ports.mips.devel,gmane.os.netbsd.devel.userlevel,gmane.os.netbsd.general,gmane.os.netbsd.devel.embedded,gmane.os.netbsd.devel.general,gmane.os.netbsd.help,gmane.os.netbsd.bugs |
|---|---|
| Message-ID | <[email protected]> |
On Sat, Jun 17, 2006 at 05:55:23PM +0530, sushant mathur wrote: > But I am facing one problem if i declared some global varriables and in > first call to that function I assign those varriables some value ,but when i > come back from that shared library to main and then later if i call some > another functions from that library then the pointers are getting > reinitialized to the initial values. I'm not sure what you are expecting - it seems that you want variables to be shared between different processes. Each process using a shared library, of course, gets it's own set of global variables in that library. If you want shared data, the library would need to create/attach some shared memory segment. Martin P.S.: please avoid massive cross-posting