]> granicus.if.org Git - file/commitdiff
drop the count of digits allowed.
authorChristos Zoulas <christos@zoulas.com>
Wed, 16 Sep 2015 22:52:54 +0000 (22:52 +0000)
committerChristos Zoulas <christos@zoulas.com>
Wed, 16 Sep 2015 22:52:54 +0000 (22:52 +0000)
src/apprentice.c

index 2089e63a97aab23333c51f0a85f15eebf2e69905..cbb058981d7d7a9de9ffa65c14425824299d72a6 100644 (file)
@@ -32,7 +32,7 @@
 #include "file.h"
 
 #ifndef        lint
-FILE_RCSID("@(#)$File: apprentice.c,v 1.240 2015/09/16 18:34:21 christos Exp $")
+FILE_RCSID("@(#)$File: apprentice.c,v 1.241 2015/09/16 22:52:54 christos Exp $")
 #endif /* lint */
 
 #include "magic.h"
@@ -2348,7 +2348,7 @@ check_format_type(const char *ptr, int type, const char **estr)
 #define CHECKLEN() do { \
        for (len = cnt = 0; isdigit((unsigned char)*ptr); ptr++, cnt++) \
                len = len * 10 + (*ptr - '0'); \
-       if (cnt > 10 || len > 1024) \
+       if (cnt > 5 || len > 1024) \
                goto toolong; \
 } while (/*CONSTCOND*/0)