2
1
mirror of https://github.com/qpdf/qpdf.git synced 2024-12-22 19:08:59 +00:00

cast arg to isspace to unsigned char

git-svn-id: svn+q:///qpdf/trunk@683 71b93d88-0707-0410-a8cf-f5a4172ac649
This commit is contained in:
Jay Berkenbilt 2009-07-13 00:42:48 +00:00
parent 9bc73a49ed
commit 7acc0498eb

View File

@ -1342,7 +1342,8 @@ QPDF::readToken(InputSource* input)
} }
else else
{ {
if (isspace(ch) && (input->getLastOffset() == offset)) if (isspace((unsigned char)ch) &&
(input->getLastOffset() == offset))
{ {
++offset; ++offset;
} }
@ -1460,7 +1461,7 @@ QPDF::readObjectAtOffset(off_t offset, int exp_objid, int exp_generation,
char ch; char ch;
if (this->file.read(&ch, 1)) if (this->file.read(&ch, 1))
{ {
if (! isspace(ch)) if (! isspace((unsigned char)ch))
{ {
this->file.seek(-1, SEEK_CUR); this->file.seek(-1, SEEK_CUR);
break; break;