in reply to Perl forking and shared memory strangeness under Windows
When you fork in AS perl under win32 (I think cygwin builds work differently), you aren't creating another process, You are instantiating another interpreter on a new thread. That's the tie-in to iThreads.
The "Free to wrong pool" indicates that a piece of memory allocated by one instance of the interpreter has come up for destruction by a different interpreter.
Quite how this is alleviated by the presence of a commented out line that references no variables I can't imagine, but as a fix, you might try requireing Win32::MMF::Shareable within each branch of the if( fork ) { statement.
I'm hazarding a guess that some load-time (BEGIN|INIT|CHECK} code is allocating a variable in the parent thread and the child thread is inheriting it and trying to free it.
This is mostly guesswork, but it would be worth a try.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Perl forking and shared memory strangeness under Windows
by Roger (Parson) on Feb 23, 2004 at 06:54 UTC | |
by BrowserUk (Patriarch) on Feb 23, 2004 at 08:12 UTC |