Nitrox has asked for the wisdom of the Perl Monks concerning the following question:
I'm trying to access a blessed reference to a tied hash from a child thread and I'm going nuts in the process. Could someone shed some light on how to accomplish this?
At the point the "object" is created by the parent print $HS returns:
Win32::OLE=HASH(0x296b448)
and print Dumper(\$HS) returns:
So all is good up to this point. The parent then spawns a child and the same code run in the child thread produces:$VAR1 = \bless( { 'plugin' => undef, 'ThreadID' => 1124, 'NoLog' => 0, 'hwnd' => 1900794, 'DebugMode' => 0, 'EventCount' => 2, 'DeviceCount' => 2, 'LastCommandSelected' => undef, 'SunRise' => '7:02 AM', 'SunSet' => '4:13 PM' }, 'Win32::OLE' );
Win32::OLE=HASH(0x437c94c)
Calling Dumper(\$HS) in the child crashes the application without any output to stderr/out. Even trying print $HS->{SunSet} causes the same crash.
This is all I want for Christmas.
-Nitrox
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: Threads and object access
by djantzen (Priest) on Dec 11, 2002 at 19:26 UTC | |
Re: Threads and object access
by Nitrox (Chaplain) on Dec 11, 2002 at 19:39 UTC | |
by djantzen (Priest) on Dec 11, 2002 at 19:50 UTC | |
Re: Threads and object access
by Nitrox (Chaplain) on Dec 11, 2002 at 21:22 UTC | |
Re: Threads and object access
by BrowserUk (Patriarch) on Dec 11, 2002 at 21:39 UTC | |
Re: Threads and object access
by Nitrox (Chaplain) on Dec 11, 2002 at 22:34 UTC | |
by BrowserUk (Patriarch) on Dec 12, 2002 at 00:07 UTC | |
by Nitrox (Chaplain) on Dec 12, 2002 at 01:44 UTC | |
by BrowserUk (Patriarch) on Dec 12, 2002 at 01:53 UTC | |
by Nitrox (Chaplain) on Dec 12, 2002 at 03:03 UTC |
Back to
Seekers of Perl Wisdom