X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=pod%2Fperlthrtut.pod;h=8e4e4f6063bd80d173e51a0a74b82ef4b9bc9cda;hb=28b41a8090d259cff9b1dd87c0c53b3c4a31e822;hp=7cac46fc55fdd0edc3613f0d23ebe989c1ae1d74;hpb=536bca942469fa9de37d172f93da54442b8d2ad7;p=p5sagit%2Fp5-mst-13.2.git diff --git a/pod/perlthrtut.pod b/pod/perlthrtut.pod index 7cac46f..8e4e4f6 100644 --- a/pod/perlthrtut.pod +++ b/pod/perlthrtut.pod @@ -602,7 +602,7 @@ communications between threads. =head2 Semaphores: Synchronizing Data Access Semaphores are a kind of generic locking mechanism. In their most basic -form, they behave very much like lockable scalars, except that thay +form, they behave very much like lockable scalars, except that they can't hold data, and that they must be explicitly unlocked. In their advanced form, they act like a kind of counter, and can allow multiple threads to have the 'lock' at any one time. @@ -985,9 +985,10 @@ Further examples of process-scope changes include umask() and changing uids/gids. Thinking of mixing fork() and threads? Please lie down and wait -until the feeling passes-- but in case you really want to know, -the semantics is that fork() duplicates all the threads. -(In UNIX, at least, other platforms will do something different.) +until the feeling passes. Be aware that the semantics of fork() vary +between platforms. For example, some UNIX systems copy all the current +threads into the child process, while others only copy the thread that +called fork(). You have been warned! Similarly, mixing signals and threads should not be attempted. Implementations are platform-dependent, and even the POSIX