This is the mail archive of the
glibc-bugs@sourceware.org
mailing list for the glibc project.
[Bug stdio/15929] scanf doesn't set errno to ERANGE for unsigned short overflows
- From: "schwab at linux-m68k dot org" <sourceware-bugzilla at sourceware dot org>
- To: glibc-bugs at sourceware dot org
- Date: Wed, 04 Sep 2013 12:42:18 +0000
- Subject: [Bug stdio/15929] scanf doesn't set errno to ERANGE for unsigned short overflows
- Auto-submitted: auto-generated
- References: <bug-15929-131 at http dot sourceware dot org/bugzilla/>
https://sourceware.org/bugzilla/show_bug.cgi?id=15929
--- Comment #1 from Andreas Schwab <schwab@linux-m68k.org> ---
POSIX does not specify ERANGE for fscanf. The ERANGE error comes from strtoul
which checks against ULONG_MAX (not UINT_MAX). If you want to do range
checking you have to do it yourself.
--
You are receiving this mail because:
You are on the CC list for the bug.