As part of an application we're developing, we use
CreateFileMapping/MapViewOfFile to be able to share information among
processes.  I noticed today that if I try to reference the map
immediately after calling fork() but before calling exec, that my
application will crash.

I should be able to resolve this in my app but I was just curious if
this was unexpected behavior or not.

I've attached a test program parent_test.cpp and my cygcheck.out.

######################
[EMAIL PROTECTED] ~
$ gcc -Wall parent_test.cpp -o parent_test

[EMAIL PROTECTED] ~
$ ./parent_test.exe
Dumping map in parent
--> length = 11
--> name = test-string
Dumping map in child
    17 [main] parent_test 2460 _cygtls::handle_exceptions: Error while dumping
state (probably corrupted stack)

[EMAIL PROTECTED] ~
$
######################

Sean

Attachment: parent_test.cpp
Description: Binary data

Attachment: cygcheck.out
Description: Binary data

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

Reply via email to