diff options
author | Ruslan Ermilov <ru@FreeBSD.org> | 2008-04-24 07:49:00 +0000 |
---|---|---|
committer | Ruslan Ermilov <ru@FreeBSD.org> | 2008-04-24 07:49:00 +0000 |
commit | eff93c8073fac6bbea85067fd1bd804982770c76 (patch) | |
tree | 5d8f9178631111f6abf139a34d6f13038c08572d /lib/libc/stdlib/strfmon.c | |
parent | 22dd049f7b221d495f03d9583f11973db7f4dda1 (diff) |
Notes
Diffstat (limited to 'lib/libc/stdlib/strfmon.c')
-rw-r--r-- | lib/libc/stdlib/strfmon.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/libc/stdlib/strfmon.c b/lib/libc/stdlib/strfmon.c index 20c69be422cb..f12c8decce5e 100644 --- a/lib/libc/stdlib/strfmon.c +++ b/lib/libc/stdlib/strfmon.c @@ -65,6 +65,8 @@ __FBSDID("$FreeBSD$"); #define GET_NUMBER(VAR) do { \ VAR = 0; \ while (isdigit((unsigned char)*fmt)) { \ + if (VAR > INT_MAX / 10) \ + goto e2big_error; \ VAR *= 10; \ VAR += *fmt - '0'; \ if (VAR < 0) \ |