aboutsummaryrefslogtreecommitdiff
path: root/stdio-common
AgeCommit message (Collapse)AuthorFilesLines
2014-02-10Use glibc_likely instead __builtin_expect.Ondřej Bílka5-44/+44
2014-01-07Fix integer overflow in vfwprintf. Fixes bug 14286.Ondřej Bílka1-1/+7
2014-01-01Update copyright notices with scripts/update-copyrightsAllan McRae87-87/+87
2013-11-18Do not let scanf("%4p") accept "(nil)". Fixes bug 16055Ondřej Bílka2-1/+3
2013-10-31Fix parsing of 0e+0 as floatAndreas Schwab2-0/+36
2013-10-29Let tst-swscanf find its localeAndreas Schwab1-0/+1
2013-10-12Fix typos.Yuri Chornoivan1-1/+1
2013-10-11Fix fwrite() reading beyond end of buffer in error pathEric Biggers1-6/+6
Partially revert commits 2b766585f9b4ffabeef2f36200c275976b93f2c7 and de2fd463b1c0310d75084b6d774fb974075a4ad9, which were intended to fix BZ#11741 but caused another, likely worse bug, namely that fwrite() and fputs() could, in an error path, read data beyond the end of the specified buffer, and potentially even write this data to the file. Fix BZ#11741 properly by checking the return value from _IO_padn() in stdio-common/vfprintf.c.
2013-10-04PowerPC floating point little-endian [1 of 15]Alan Modra3-17/+12
http://sourceware.org/ml/libc-alpha/2013-08/msg00081.html This is the first of a series of patches to ban ieee854_long_double and the ieee854_long_double macros when using IBM long double. union ieee854_long_double just isn't correct for IBM long double, especially when little-endian, and pretending it is OK has allowed a number of bugs to remain undetected in sysdeps/ieee754/ldbl-128ibm/. This changes the few places in generic code that use it. * stdio-common/printf_size.c (__printf_size): Don't use union ieee854_long_double in fpnum union. * stdio-common/printf_fphex.c (__printf_fphex): Likewise. Use signbit macro to retrieve sign from long double. * stdio-common/printf_fp.c (___printf_fp): Use signbit macro to retrieve sign from long double. * sysdeps/ieee754/ldbl-128ibm/printf_fphex.c: Adjust for fpnum change. * sysdeps/ieee754/ldbl-128/printf_fphex.c: Likewise. * sysdeps/ieee754/ldbl-96/printf_fphex.c: Likewise. * sysdeps/x86_64/fpu/printf_fphex.c: Likewise. * math/test-misc.c (main): Don't use union ieee854_long_double. ports/ * sysdeps/ia64/fpu/printf_fphex.c: Adjust for fpnum change.
2013-09-24Fix tst-long-dbl-fphex swprintf length calculation.Olivier Langlois1-2/+2
2013-08-30Fix typos.Ondřej Bílka1-1/+1
2013-06-07Avoid use of "register" as optimization hint.Joseph Myers8-25/+25
2013-06-06Fix leading whitespaces.Ondrej Bilka1-1/+1
2013-06-05Remove trailing whitespace.Joseph Myers1-1/+1
2013-05-26 * stdio-common/bug26.c (main): Correct fscanf template.Thomas Schwinge1-2/+3
Fixup for commit 6ecec3b616aeaf121c68c1053cd17fdcf0cdb5a2.
2013-04-15Fix coding-style violation.Thomas Schwinge1-4/+4
Introduced in commit ee091edf1a16312fff0cc3c6ae0116aded7f1dbf.
2013-04-11Don't accept exp char without preceding digits in scanf float parsingAndreas Schwab3-6/+49
2013-04-05More tests for external charater sequences representing NaNs.Thomas Schwinge1-1/+61
2013-04-05Properly collect individual tests' results.Thomas Schwinge1-5/+5
Fixup for commit 003c9895a89e71767ad64bafac1ca99622be2eb7.
2013-03-15Better distinguish between NaN/qNaN/sNaN.Thomas Schwinge1-18/+20
2013-03-15Remove unused declarations.Thomas Schwinge1-3/+0
Added in commit f83af095b6fc49de3914f4426202171341783277, and forgotten to be removed in commit 76f2646f3dbe45d3ed53a0c73fa52f1595306b35.
2013-03-05Replace __builtin_expect(..., 0) with __glibc_unlikely().Paul Pluzhnikov1-19/+19
2013-03-05 * stdio-common/vfprintf.c (vfprintf): Check malloc return; don'tPaul Pluzhnikov1-4/+13
call free(NULL).
2013-02-13Remove __ptrvalue, __bounded and __unbounded.Joseph Myers1-2/+2
2013-01-11Add --enable-hardcoded-path-in-tests configure optionH.J. Lu3-7/+7
2013-01-02Update copyright notices with scripts/update-copyrights.Joseph Myers86-95/+86
2013-01-01Add script to update copyright notices and reformat some to facilitate its use.Joseph Myers1-2/+1
2012-12-06Add newline to last test in stdio-common/tst-put-error.cSiddhesh Poyarekar1-1/+11
The newline ensures that the buffer is flushed and the test executes as expected.
2012-12-05Increase width of padded output in stdio-common/tst-put-error.Joseph Myers1-1/+1
2012-11-20Fix more set-but-not-used warnings in _itowa.c.Joseph Myers1-2/+4
2012-11-16printf should return negative value on errorSiddhesh Poyarekar2-4/+50
[BZ #11741] Fixed bug where printf and family may return a spurious success when printing padded formats.
2012-11-04[BZ #157] Remove include/stub-tag.h for good.Thomas Schwinge6-6/+0
2012-10-24Define and use $(run-built-tests).Joseph Myers1-1/+1
2012-09-282012-09-28 Andreas Schwab <schwab@linux-m68k.org>Jeff Law3-36/+17
[BZ #6530] * stdio-common/vfprintf.c (process_string_arg): Revert 2000-07-22 change. 2011-09-28 Jonathan Nieder <jrnieder@gmail.com> * stdio-common/Makefile (tst-sprintf-ENV): Set environment for testcase. * stdio-common/tst-sprintf.c: Include <locale.h> (main): Test sprintf's handling of incomplete multibyte characters.
2012-09-25Set "fail on error" mode directly in testsuite shell scriptsDmitry V. Levin3-9/+11
2012-09-24Make printf respect the rounding mode for hex output (bug 5044).Joseph Myers2-13/+151
2012-09-14Make printf respect the rounding mode for decimal output (bug 5044).Joseph Myers3-30/+142
2012-08-18Fix last patch: Add missing DUMMY variableAndreas Jaeger1-2/+2
2012-08-17Clean up definition of _LIBC_REENTRANT and _IO_MTSAFE_IO.Roland McGrath2-3/+5
2012-08-16Suppress -Wunused-but-set warnings in GMP code.Roland McGrath2-9/+15
2012-07-30Fix lots of bitrot for stub configurations.Roland McGrath5-5/+37
2012-06-01Remove use of INTDEF/INTUSE in stdio-commonAndreas Schwab5-39/+16
2012-05-242012-05-24 Jeff Law <law@redhat.com>Jeff Law2-1/+72
* stdio-common/Makefile (tests): Add bug25. * stdio-common/bug25.c: New test.
2012-05-24Remove use of INTDEF/INTUSE in libioAndreas Schwab18-58/+54
2012-05-21[BZ #13691], Revert breakage of iconv() converter for TCVN-5712.Andreas Jaeger2-12/+1
* iconvdata/tcvn5712-1.c (BODY for FROM_LOOP): Don't consider inptr and inend for must_buffer_ch. * wcsmbs/tst-mbsnrtowcs.c: Remove file. * wcsmbs/Makefile (tests): Remove tst-mbsnrtowcs. * stdio-common/Makefile (tests): Remove bug15. (bug15-ENV): Remove macro. * stdio-common/bug15.c: Remove, we do not support vi_VN.TCVN5712-1 anymore. localedata: * SUPPORTED: Remove vi_VN.TCVN/TCVN5712-1. * tst-strptime.c: Remove, we do not support vi_VN.TCVN5712-1 anymore. * Makefile (LOCALES): Remove vi_VN.TCVN5712-1 from list. (tests): Remove tst-strptime.
2012-05-18Check _ITOA_NEEDED and use _ITOA_WORD_TYPEH.J. Lu1-5/+6
2012-05-17Bump up stdio bug22 timeout from 30 seconds to 60 secondsChris Metcalf1-1/+1
The older Tilera platform (tilepro) needs just a hair over 30 seconds to run this on one core.
2012-04-28Fix formatting of denormal IBM long double numbersAndreas Schwab2-1/+91
2012-04-02Tighten up vfprintf width, precision, and total length overflow handling.David S. Miller4-39/+131
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-03-21Add _ITOA_NEEDED and _ITOA_WORD_TYPEH.J. Lu2-2/+9
Add _ITOA_NEEDED and _ITOA_WORD_TYPE to override _itoa and _itowa.