Threads - "Attempt to free non-existent shared string"

M

MoshiachNow

HI,

Just beginning with threads...
Code:

$thr = threads->create({'context' => 'void'},\&THREAD,$computer);
sub THREAD {
$computer=shift;
print "COMPUTER=$computer\n";
$objWMIService =
Win32::OLE->GetObject("winmgmts:\\\\$computer\\root\\CIMV2") or
&disp("WMI connection failed.\n",'RED');
$colItems = $objWMIService->ExecQuery("SELECT * FROM
Win32_Product", "WQL",
wbemFlagReturnImmediately | wbemFlagForwardOnly);
}
$thr->join();

=============================================
result:

"Attempt to free non-existent shared string 'ExecQuery', Perl
interpreter: 0x235d27c at D:\
DOcuments\Ripro\AIX\myscripts\pod_check.pl line 988.
Free to wrong pool 218fd28 not 222770 at
D:\DOcuments\Ripro\AIX\myscripts\pod_check.pl lin
e 988."

The thing is that 'ExecQuery' WAS working well till put in
thread...Appreciate ideas.
Thanks
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,969
Messages
2,570,161
Members
46,705
Latest member
Stefkari24

Latest Threads

Top