Hi,<br><div class="gmail_quote"><br>I am porting kamailio to the OS which doesnt support fork. For the OS, tasks are similar to threads of same process in Linux.<br><br>In this environment, child task(s) will share the global and heap data with parent instead of having separate copy of the data.<br>

Its analogus to using mutiple threads instead of multiple processes in kamailio.<br><br>My question is , kamailio supports USE_SHM_MEM which allows all the pkg_mallocs to become shm_malloc. This way<br>I dont need to be concerned about access of data in heap while porting because code is designed that way. <br>

Is my understanding true? <br><br>&nbsp;How are the global variables accessed? especially, though data is in shared mem, the variable holding address of data is defined as<br>global variable. <br><br>So,after fork parent and child both interprete global data differently or is there any design rule enforced that after fork no.process <br>

will be writing global data. (igonre the cleanup for a while). Will there be any any problem if I dont give child task its own copy of<br>global variables and let them use the same copy as parent?<br><br>Please guide me.<br>

<br>Regards,<br><font color="#888888">Kalpesh<br><br></font></div><br>