David S. Miller
135ffda8b8
Tighten up vfprintf width, precision, and total length overflow handling.
...
With help from Paul Eggert, Carlos O'Donell, and Roland McGrath.
* stdio-common/printf-parse.h (read_int): Change return type to
'int', return -1 on INT_MAX overflow.
* stdio-common/vfprintf.c (vfprintf): Validate width and precision
against overflow of INT_MAX. Set errno to EOVERFLOW when 'done'
overflows INT_MAX. Check for overflow of in-format-string precision
values properly. Use EOVERFLOW rather than ERANGE throughout. Use
SIZE_MAX not INT_MAX for integer overflow test.
* stdio-common/printf-parsemb.c: If read_int signals an overflow,
skip the construct in the format string but do not record anything.
* stdio-common/bug22.c: Adjust to test both width/prevision
INT_MAX overflow as well as total length INT_MAX overflow. Check
explicitly for proper errno values.
2012-04-02 14:31:19 -07:00
..
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-03-20 16:00:23 -07:00
2012-03-21 14:38:47 -07:00
2012-03-21 14:38:47 -07:00
2012-02-09 23:18:22 +00:00
2007-10-28 16:45:27 +00:00
2007-12-07 16:50:11 +00:00
2012-04-02 14:31:19 -07:00
2011-02-20 07:59:49 -05:00
2011-08-20 09:22:16 -04:00
2012-03-10 00:45:35 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-03-09 22:05:49 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-03-20 16:00:23 -07:00
2012-02-09 23:18:22 +00:00
2012-04-02 14:31:19 -07:00
2012-04-02 14:31:19 -07:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2009-02-26 06:18:24 +00:00
2009-02-26 06:18:24 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2009-10-30 09:23:24 -07:00
2008-05-24 18:14:36 +00:00
2009-07-29 08:33:03 -07:00
2008-05-24 18:14:36 +00:00
2009-07-29 08:33:03 -07:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-27 13:29:12 -08:00
2012-03-08 03:02:24 -05:00
2012-03-08 03:02:24 -05:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2011-01-12 20:37:51 -05:00
2012-03-08 02:46:43 -05:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2008-07-08 16:32:55 +00:00
2008-07-08 16:32:55 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2009-08-23 11:57:52 -07:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2009-04-11 05:34:20 +00:00
2012-04-02 14:31:19 -07:00
2012-02-09 23:18:22 +00:00
2012-02-09 23:18:22 +00:00
2012-01-30 21:20:32 +00:00