Skip Menu |

This queue is for tickets about the HTML-Tagreader CPAN distribution.

Report information
The Basics
Id: 114594
Status: new
Priority: 0/
Queue: HTML-Tagreader

People
Owner: Nobody in particular
Requestors: pterjan [...] gmail.com
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: 1.10
Fixed in: (no value)



Subject: Hangs on arm due to the assumption that char == signed char
The tests hang on arm, after debugging this is due to the read character never being equal to EOF. This is because the character variables have type char while they need to be signed char to be able to compare to EOF (-1). On most platforms char defaults to signed, but the C standard says it can be either signed or unsigned and on arm it defaults to unsigned. The attached patch fixes it.
Subject: HTML-TagReader-1.10-signed-char.patch
--- HTML-TagReader-1.10/TagReader.xs~ 2004-07-31 22:44:38.000000000 +0100 +++ HTML-TagReader-1.10/TagReader.xs 2016-05-22 16:47:48.266594075 +0100 @@ -115,8 +115,8 @@ SV *showerrors PREINIT: int bufpos; - char ch; - char chn; + signed char ch; + signed char chn; int state; PPCODE: if (! self->fileline){ @@ -260,8 +260,8 @@ SV *showerrors PREINIT: int bufpos; - char ch; - char chn; /* next character */ + signed char ch; + signed char chn; /* next character */ int typepos; int typeposdone; int state;