- Use of broken 'isalpha' caused 'entrée' to be parsed by Nibbler::getName
  as 'entr'.  This is part of bug #1006, but only a small part.
This commit is contained in:
Paul Beckingham
2012-06-10 16:17:09 -04:00
parent e8309fcf49
commit 9a6319a210
3 changed files with 15 additions and 9 deletions

View File

@@ -1048,12 +1048,14 @@ bool Nibbler::getName (std::string& result)
if (i < _length)
{
if (isalpha (_input[i]))
if (! isdigit (_input[i]) &&
! ispunct (_input[i]) &&
! isspace (_input[i]))
{
++i;
while (i < _length &&
(isalpha (_input[i]) ||
isdigit (_input[i])))
! ispunct (_input[i]) &&
! isspace (_input[i]))
{
++i;
}