Getting "No error" instead of "No such file or directory" on Win32

Hi all,

in this CPAN testers XML-LibXML test failure:

http://www.cpantesters.org/cpan/report/d9cf95fc-d5e8-1017-8e8a-88a105085451

I am getting this:

[QUOTE]
t/01basic.t ......................... ok

#   Failed test 'error parsing non-existent does_not_exist.xml'
#   at t/02parse.t line 238.
#                   'Could not create file parser context for file "does_not_exist.xml": No error at t/02parse.t line 237.
# '
#     doesn't match '(?-xism:\ACould not create file parser context for file "does_not_exist\.xml": No\ such\ file\ or\ directory)'
# Looks like you failed 1 test of 531.
t/02parse.t ......................... 
Dubious, test returned 1 (wstat 256, 0x100)
Failed 1/531 subtests 

[/QUOTE]

My question is - why?

Regards,

	Shlomi Fish

-- 
-----------------------------------------------------------------
Shlomi Fish       http://www.shlomifish.org/
The Case for File Swapping - http://shlom.in/file-swap

Ran Eilam To Shlomi Fish: so what are you working on? Working on a new wiki
about unit testing fortunes in freecell?

Please reply to list if it's a mailing list post - http://shlom.in/reply .
0
shlomif2 (12)
6/24/2012 2:06:40 PM
perl.qa 2166 articles. 0 followers. Follow

1 Replies
651 Views

Similar Articles

[PageSpeed] 38

On 2012.6.24 7:06 AM, Shlomi Fish wrote:
> [QUOTE]
> t/01basic.t ......................... ok
> 
> #   Failed test 'error parsing non-existent does_not_exist.xml'
> #   at t/02parse.t line 238.
> #                   'Could not create file parser context for file "does_not_exist.xml": No error at t/02parse.t line 237.
> # '
> #     doesn't match '(?-xism:\ACould not create file parser context for file "does_not_exist\.xml": No\ such\ file\ or\ directory)'
> # Looks like you failed 1 test of 531.
> t/02parse.t ......................... 
> Dubious, test returned 1 (wstat 256, 0x100)
> Failed 1/531 subtests 
> 
> [/QUOTE]
> 
> My question is - why?

Some systems stringify an errno value of 0 as "no error".  A few things could
have caused this:

1) Something might have set errno to 0 between the failure and the error being
printed.  Many I/O operations will do this, some at the OS level.

This could be in the CLEANUP_ERROR_HANDLER or REPORT_ERROR or even inside
xmlCreateFileParserCtxt itself.

2) The failure may not have been the result of an I/O failure causing errno to
never have been set.

Is there a guarantee that xmlCreateFileParserCtxt() sets errno reliably?


-- 
Stabbing you in the face so you don't have to.
0
schwern
6/25/2012 7:45:20 PM
Reply: