On Tue, Nov 19, 2024 at 09:04:23PM +0000, Gavin Smith wrote:
> While testing texi2any, I accidentally found a bug:
> 
> $ export top_srcdir=../../ top_builddir=.. TEXINFO_DEV_SOURCE=1
> $ ./texi2any ../doc/info-stnd.info                   
> texi2any: warning: input file info-stnd.info; did you mean info-stnd.texi?
> You found a bug: Should be at end of line but have [inde]
> '
> 
> Additional information:
> last location: info-stnd.info:2106
> context_stack: (ct_base)
> current: (before_node_section)[C1078] at ../../tp/Texinfo/ParserNonXS.pm line 
> 1144.
> Died at ../../tp/Texinfo/ParserNonXS.pm line 7647.

Coming back to this, I now had to run

TEXINFO_XS_PARSER=0 ./texi2any  ../doc/info-stnd.texi

to get the error on this system (OpenBSD 7.5).  It was being exposed befor
by some of the XS modules not loading correctly.  Just disabling
the XS modules completely, as with:

TEXINFO_XS=omit ./texi2any  ../doc/info-stnd.info

doesn't produce the error.

Perl reports version 5.36.3.

It fails on a short input file:

---------------cut
File: info-stnd.info,  Node: Index

Appendix A Index
****************

^@^H[index^@^H]
* Menu:
     
* _info file (MS-DOS):                   Custom Key Bindings. (line   6)
* -:                                     Miscellaneous Commands.
                                                              (line  72)
* --all (-a) command line option:        Invoking Info.       (line  97)
---------------cut

where ^@ and ^H are single bytes (null and backspace).

I see you now have made changes (2024-12-01) for handling null bytes
in ParserNonXS.pm, so perhaps the issue is fixed in the most recent
development version.  (I was testing this with an older version of
the code.)

Reply via email to