I just got a reproduced crash with an instrumented vms.c.
Here is the code fragment:
my $Null = '_NLA0:';
print STDERR "# stat.t1 step 7 - Null = $Null\n\n";
#SKIP: {
# skip "No null device to test with", 1 unless -e $Null;
my $isnull1 = -e '/dev/null';
print STDERR "# stat.t1 step 8.1\n\n";
my $isnull1 = -e '_NLA0:';
print STDERR "# stat.t1 step 8.2\n\n";
-e $Null;
print STDERR "# stat.t1 step 8.3\n\n";
my $isnull = -e $Null;
print STDERR "# stat.t1 step 8.4\n\n";
Here is the output:
# stat.t1 step 7 - Null = _NLA0:
Entering Perl_flex_stat_int
Exiting Perl_flex_stat_int
# stat.t1 step 8.1
Entering Perl_flex_stat_int
Exiting Perl_flex_stat_int
# stat.t1 step 8.2
Entering Perl_flex_stat_int
Entering Perl_flex_stat_int
Exiting Perl_flex_stat_int
Entering Perl_flex_stat_int
Exiting Perl_flex_stat_int
dubious
Test returned status 12 (wstat 1024, 0x400)
FAILED--1 test script could be run, alas--no output ever seen
%SYSTEM-F-ACCVIO, access violation, reason mask=00,
virtual address=000000000000000C, PC=0000000000000012, PS=00000003
The entering and exiting were output by the fputs() statement that I added.
What is curious is that Perl_flex_stat_int was called 3 times when the
file specification was passed in a variable, yet only once when the file
specification was passed as a string constant.
Even more interesting is that Perl_flex_stat appears to be called
recursively in this case, as it is entered twice before it is exited once.
I am no longer getting an access violation on every run with this test
script. When there is no access violation, Perl_flex_stat_int is only
called once for that step.
I can find no cases where Perl_flex_stat_int could recursively call it
self either directly or indirectly.
So this looks like a case where the stack has become corrupt so that it
is returning to the wrong place.
But why is it only doing this for a variable and not a constant?
And why is it only doing this some of the time?
This is all I have time for tonight.
I think I might put in a test to see if ((strncmp(fspec,"_NLA0:",6) ==
0) && (fspec[6] != 0)) ever shows up.
-John
[EMAIL PROTECTED]
Personal Opinion Only