nplurals must be positive.
authordrepper <drepper>
Tue, 27 Nov 2001 22:41:08 +0000 (22:41 +0000)
committerdrepper <drepper>
Tue, 27 Nov 2001 22:41:08 +0000 (22:41 +0000)
intl/plural-exp.c

index 946a375..ba5d455 100644 (file)
@@ -121,6 +121,8 @@ EXTRACT_PLURAL_EXPRESSION (nullentry, pluralp, npluralsp)
          nplurals += 9;
          while (*nplurals != '\0' && isspace ((unsigned char) *nplurals))
            ++nplurals;
+         if (!(*nplurals >= '0' && *nplurals <= '9'))
+           goto no_plural;
 #if defined HAVE_STRTOUL || defined _LIBC
          n = strtoul (nplurals, &endp, 10);
 #else