In attempting to figure out why taint.t #73 fails on VMS I reduced 
the issue to the following:

$  perl -e "open qq/<nofile.dat/; print eval('$!{ENOENT}');"
0

which should print 2 to report the no such file error.  With help
from various folks I realized that the issue is that Errno.pm is
being loaded at run-time and surmised that something is resetting 
errno when that happens.

The culprit turns out to be the following section of code from 
yyparse in perly.c:

#if YYDEBUG
    if ((yys = getenv("YYDEBUG")))
    {
        yyn = *yys;
        if (yyn >= '0' && yyn <= '9')
            yydebug = yyn - '0';
    }
        else SETERRNO(0,SS$_NORMAL);
#endif


As far as I can tell, the macro YYDEBUG will always be defined to 
true when DEBUGGING is enabled.  I would think this would be a 
problem for anything involving errno that also involves parsing at 
run-time, and I don't see offhand why it would be a VMS-only problem. 
Or is it common for folks to have YYDEBUG defined in the environment, 
which would prevent the resetting of errno?  There are no occurrences 
of the string "YYDEBUG" in the pod directory and so far I haven't 
found comments in the code that would give me any clue about what it 
is or why it resets errno.  Any help appreciated.

-- 
________________________________________
Craig A. Berry
mailto:[EMAIL PROTECTED]

"... getting out of a sonnet is much more
 difficult than getting in."
                 Brad Leithauser

Reply via email to