Re: Fork mystries....

2005-06-04 Thread Aziz Kezzou
Thank you guys, I got it fork is creating a different process. Currently, I am working a lot that I forget even the basic principales ;-) I need a break ... -aziz On 6/3/05, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: Aziz, Fork is for process creation. Look up pthread_create() and/or

Fork mystries....

2005-06-03 Thread Aziz Kezzou
Hi all, It's probably not the right mailing list to ask but I am really surprised about global variable sharing in a multithreaded C application. If I remember well my multithreading course global variables are shared between threads, right ? Example : int counter =

Re: Fork mystries....

2005-06-03 Thread Joerg Sonnenberger
On Fri, Jun 03, 2005 at 07:55:29PM -0400, Aziz Kezzou wrote: It's probably not the right mailing list to ask but I am really surprised about global variable sharing in a multithreaded C application. If I remember well my multithreading course global variables are shared between threads, right

Re: Fork mystries....

2005-06-03 Thread Daniel Eischen
On Fri, 3 Jun 2005, Aziz Kezzou wrote: Hi all, It's probably not the right mailing list to ask but I am really surprised about global variable sharing in a multithreaded C application. If I remember well my multithreading course global variables are shared between threads, right ? Uhh,

Re: Fork mystries....

2005-06-03 Thread Julian Elischer
Aziz Kezzou wrote: Hi all, It's probably not the right mailing list to ask but I am really surprised about global variable sharing in a multithreaded C application. If I remember well my multithreading course global variables are shared between threads, right ? fork() is not a threading

Re: Fork mystries....

2005-06-03 Thread ray
Aziz, Fork is for process creation. Look up pthread_create() and/or POSIX thread creation, etc. You should be able to find a lot of info on google with a quick search: http://math.arizona.edu/~swig/documentation/pthreads/ From the OS standpoint a process is like a different program when