cpan-authors / XML-Parser

Perl module for parsing XML documents with libexpat.
Artistic License 2.0
8 stars 20 forks source link

XML::Parser::Expat::current_byte() reports negative offsets for large files [rt.cpan.org #14583] #36

Open toddr opened 5 years ago

toddr commented 5 years ago

Migrated from rt.cpan.org#14583 (status was 'new')

Requestors:

From on 2005-09-14 12:28:09

XML::Parser::Expat::current_byte() reports negative offsets for large files -- I discovered this by piping data from the Wikipedia dump files into this script: https://secure.mysociety.org/cvstrac/getfile/mysociety/placeopedia/bin/wikipediatitles?v=1.2 after 2**31 bytes, it starts printing negative progress indications.

perl 5.8.6, FreeBSD 5.2.1-RELEASE-p13, x86

Presumably the issue here is that it's using a 32-bit counter for the file offset. perl is compiled with -Duse64bitint, so I don't think this is a limitation of the perl interpreter.

toddr commented 5 years ago

Given the rarity of 32bit at this point, I'm declining to look into this. Patches are welcome.