Posted on 2005-04-27 16:50:05-07 by lmiphay
Unusual error with 0.26, perl 5.8.1, Solaris 8
First the error message:

pread error reading command line arguments: Bad file number
pread of initial environment location: Bad file number
Attempt to free unreferenced scalar at
/opt/fraudoffice/lib/perl5/site_perl/5.8.1/sun4-solaris/Solaris/Procfs.pm line 226 (#1)
(W internal) Perl went to decrement the reference count of a scalar to
see if it would go to 0, and discovered that it had already gone to 0
earlier, and should have been freed, and in fact, probably was freed.
This could indicate that SvREFCNT_dec() was called too many times, or
that SvREFCNT_inc() was called too few times, or that the SV was
mortalized when it shouldn't have been, or that memory has been
corrupted.

Attempt to free unreferenced scalar at
/opt/fraudoffice/lib/perl5/site_perl/5.8.1/sun4-solaris/Solaris/Procfs/Process.pm line 238 (#1)
The program uses Solaris::Procfs like this:

use Solaris::Procfs;
use Solaris::Procfs::Filesystem;

$main::fs = new Solaris::Procfs::Filesystem;

my ($psinfo) = $main::fs->{$pid}->{psinfo};

my ($usage) = $main::fs->{$pid}->{usage};

If pid isn't valid perhaps? Has anyone seen anything like this before?

Thanks,

Paul
Direct Responses: Write a response
Perl Weekly newsletter
A free weekly newsletter for people who are busy to read all the blogs. click here to check it out.