summaryrefslogtreecommitdiffstats
path: root/newlib/libc
Commit message (Collapse)AuthorAgeFilesLines
* * libc/time/mktime.c (mktime): Lock global timezone info whileCorinna Vinschen2011-06-271-0/+4
| | | | accessing it.
* * libc/time/asctime_r.c (asctime_r): Replace call to sprintf with callCorinna Vinschen2011-06-143-5/+8
| | | | | | to siprintf. * libc/time/strftime.c: Define snprintf to sniprintf in multibyte case. * libc/time/tzset_r.c: Define sscanf to siscanf.
* libgloss:Joseph Myers2011-06-142-14/+6
| | | | | | | | | | | | | | | * configure.in: Don't handle strongarm, ep9312 and xscale target names. * configure: Regenerate. * libnosys/configure.in: Don't handle strongarm and thumb target names. * libnosys/configure: Regenerate. newlib: * configure.host: Don't handle ep9312, strongarm, xscale and thumb target names. * libc/machine/configure.in: Don't handle xscale target names. * libc/machine/configure: Regenerate.
* * libc/time/tzset_r.c (tzset_r): Correct behavior for changing fromCorinna Vinschen2011-06-141-1/+5
| | | | | non-GMT to GMT, when un-setting TZ. Set _timezone and _daylight even if no DST is given in TZ.
* printf: set errno for read-only streamEric Blake2011-06-144-15/+19
| | | | | | | * libc/stdio/wsetup.c (__swsetup_r): Set errno on failure. * libc/stdio/fvwrite.c (__sfvwrite_r): Simplify. * libc/stdio/wbuf.c (__swbuf_r): Likewise. * libc/stdio/local.h (cantwrite): Adjust comment.
* 2011-06-09 Yaakov Selkowitz <yselkowitz@...>Jeff Johnston2011-06-101-0/+14
| | | | | * libc/include/string.h (strdupa): New macro function. (strndupa): New macro function.
* * v8500/sbrk.c (_sbrk): Tidy code.Nick Clifton2011-05-271-19/+12
| | | | | | | Base start of heap on the "heap_start" symbol. * libc/sys/sysnecv850/sbrk.c (_sbrk): Tidy code. Base start of heap on the "heap_start" symbol.
* * libc/string/strerror.c (_strerror_r): Report "Success" for 0.Eric Blake2011-05-251-0/+6
|
* strerror: allow user hook to comply with POSIX rulesEric Blake2011-05-257-27/+62
| | | | | | | | | | | * libc/string/strerror.c (strerror): Split body into... (_strerror_r): ...new reentrant function. * libc/string/u_strerr.c (_user_strerror): Update signature. * libc/include/stdio.h (_strerror_r): New prototype. * libc/posix/collate.c (__collate_err): Adjust callers. * libc/stdio/perror.c (_perror_r): Likewise. * libc/string/strerror_r.c (strerror_r): Likewise. * libc/string/xpg_strerror_r.c (__xpg_strerror_r): Likewise.
* * libc/include/stdio_ext.h: New header.Yaakov Selkowitz2011-05-192-0/+45
| | | | * libc/stdio/fpurge.c [!__rtems__] (__fpurge): New function.
* * libc/include/time.h (CLOCK_PROCESS_CPUTIME_ID): Rename fromYaakov Selkowitz2011-05-162-4/+4
| | | | | | | CLOCK_PROCESS_CPUTIME. (CLOCK_THREAD_CPUTIME_ID): Rename from CLOCK_THREAD_CPUTIME. * libc/include/sys/features.h [__CYGWIN__] (_POSIX_CPUTIME): Define. (_POSIX_THREAD_CPUTIME): Define.
* * libc/stdlib/strtod.c (_strtod_r): Fix nf/nd counts to not exceedCorinna Vinschen2011-05-161-8/+10
| | | | DBL_DIG.
* * libc/include/sys/features.h (_POSIX_THREAD_ATTR_STACKADDR): DefineCorinna Vinschen2011-05-151-1/+1
| | | | to 200112L for Cygwin.
* * libc/time/strptime.c (strptime): Fill in tm_yday when all of tm_year,Corinna Vinschen2011-05-121-0/+81
| | | | | tm_mon and tm_mday are updated. Fill in tm_mon, tm_mday and tm_wday when both of tm_year and tm_yday are updated.
* * libc/time/strptime.c (first_day): Actually return the wdayCorinna Vinschen2011-05-121-2/+2
| | | | of the first day of the year.
* * libc/locale/lmessages.c (_C_messages_locale): Add missing comma.Corinna Vinschen2011-05-101-1/+1
|
* * libc/include/signal.h (psignal): Declare.Yaakov Selkowitz2011-05-049-50/+88
| | | | | | | | | | | * libc/sys/linux/psignal.c: Move from here... * libc/signal/psignal.c: ... to here. Document. * libc/sys/linux/Makefile.am (GENERAL_SOURCES): Move psignal.c from here... * libc/signal/Makefile.am (LIB_SOURCES): ... to here. (CHEWOUT_FILES): Add psignal.def. * libc/sys/linux/Makefile.in: Regenerate. * libc/signal/Makefile.in: Ditto. * libc/signal/signal.tex: Add references to psignal.
* * libc/locale/lmessages.h (__messages_load_locale): Declare. RemoveCorinna Vinschen2011-05-042-13/+14
| | | | | | | | | accidental declaration of __numeric_load_locale. * libc/locale/locale.c: Include timelocal.h to get declaration of __time_load_locale. (__set_locale_from_locale_alias): Fix return type. (__locale_msgcharset): Avoid compiler warnings. (_localeconv_r): Ditto.
* Cygwin-specific patch from Andy Koppe:Corinna Vinschen2011-05-041-7/+6
| | | | | | | * libc/locale/locale.c (current_categories): On Cygwin, set LC_CTYPE to C.UTF-8 to match initial __wctomb and __mbtowc settings. (lc_ctype_charset): On Cygwin, initialize to "UTF-8". (loadlocale): Remove unused Cygwin-specifc code.
* * libc/include/sys/features.h [__CYGWIN__] (_POSIX_SPIN_LOCKS): Define.Yaakov Selkowitz2011-05-022-2/+2
| | | | | * libc/include/sys/types.h: Cygwin provides its own pthread_spinlock_t typedef.
* * libc/include/sys/signal.h (_sig_func_ptr): Define with int parameterCorinna Vinschen2011-04-191-1/+2
| | | | per POSIX. Explain in comment.
* strchrnul: avoid segvEric Blake2011-04-151-3/+1
| | | | * libc/string/strchrnul.c (strchrnul): Fix strchrnul.
* Check in strchrnul.c file missing in previous checkinCorinna Vinschen2011-03-281-0/+49
|
* * libc/include/string.h (strchrnul): Declare.Corinna Vinschen2011-03-283-2/+12
| | | | | | * libc/string/strchrnul.c: New file. * libc/string/Makefile.am (ELIX_2_SOURCES): Add strchrnul.c. * libc/string/Makefile.in: Regenerate.
* * libc/machine/frv/setjmp.S: Fix typo in .size directive.Nick Clifton2011-03-231-1/+1
|
* * libc/sys/sysnecv850/trap.S (___trap0): Fix errno handling.Kevin Buettner2011-03-217-11/+36
| | | | | | | | * libc/sys/sysnecv850/rename.c: New file. * libc/sys/sysnecv850/Makefile.am (lib_a_SOURCES): Add rename.c * libc/sys/sysnecv850/Makefile.in: Regenerate. * libc/sys/sysnecv850/fstat.c (_fstat): Invoke trap for SYS_fstat. * libc/sys/sysnecv850/unlink.c (_unlink): Invoke trap for SYS_unlink.
* * libc/include/string.h: Include sys/cdefs.h.Corinna Vinschen2011-03-031-0/+1
|
* * libc/include/sys/cdefs.h (__CONCAT1): Define.Corinna Vinschen2011-03-032-1/+22
| | | | | | | | | (__CONCAT): Define. (__STRING): Define. (__XSTRING): Define. (__ASMNAME): Define. * libc/include/string.h (strerror_r): Use __ASMNAME to take target specific label prefixes into account.
* * libc/stdio/fmemopen.c (fmemopen): Fix EINVAL condition. Avoid SEGVCorinna Vinschen2011-02-221-2/+2
| | | | if incoming buffer is NULL.
* strerror_r: provide POSIX implementationEric Blake2011-02-106-13/+104
| | | | | | | | | | | * libc/include/string.h (strerror_r): Update declaration. * libc/string/strerror.c (strerror): Update documentation. * libc/string/strerror_r.c (strerror_r): Always return NUL-terminated string; don't overwrite too-short buf. * libc/string/xpg_strerror_r.c (__xpg_strerror_r): Implement POSIX variant. * libc/string/Makefile.am (GENERAL_SOURCES): Build new file. * libc/string/Makefile.in: Regenerate.
* * libc/stdio/fclose.c: Only use sfp lock to guard non-atomicCorinna Vinschen2011-01-2818-132/+75
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | changes of flags and fp lock. * libc/stdio/freopen.c: Ditto. * libc/stdio/freopen64.c: Ditto. * libc/stdio/fgetc.c: Revert change from 2009-04-24, remove sfp locks which guard entire function to avoid potential deadlocks when using stdio functions in multiple thraeds. * libc/stdio/fgets.c: Ditto. * libc/stdio/fgetwc.c: Ditto. * libc/stdio/fgetws.c: Ditto. * libc/stdio/fread.c: Ditto. * libc/stdio/fseek.c: Ditto. * libc/stdio/getc.c: Ditto. * libc/stdio/getdelim.c: Ditto. * libc/stdio/gets.c: Ditto. * libc/stdio/vfscanf.c: Ditto. * libc/stdio/vfwscanf.c: Ditto. * libc/stdio/fflush.c (_fflush_r): Split out core functionality into new function __sflush_r. Just lock file and call __sflush_r from here. * libc/stdio/fwalk.c (_fwalk): Remove static helper function and move functionality back into main function. Don't walk a file with flags value of 1. Add comment. (_fwalk_reent): Ditto. * libc/stdio/local.h (__sflush_r): Declare. * libc/stdio/refill.c (__srefill): Before calling fwalk, set flags value to 1 so this file pointer isn't walked. Revert flags afterwards and call __sflush_r for this fp if necessary. Add comments.
* * libc/include/sys/features.h: Define __STDC_ISO_10646__ for Cygwin.Corinna Vinschen2011-01-272-0/+9
| | | | * libc/include/wchar.h: Include features.h.
* * libc/include/sys/types.h (ulong): Add typedef.Corinna Vinschen2011-01-151-0/+1
|
* * libc/include/linux/sys/signal.h (sig_t): Move from here...Corinna Vinschen2011-01-122-1/+1
| | | | * libc/include/signal.h (sig_t): ...to here.
* * libc/machine/mips/strlen.c (strlen): Add delay slot for R3000.Corinna Vinschen2011-01-101-0/+3
|
* * libc/include/string.h: Make strsignal() available unconditionally.Corinna Vinschen2011-01-101-1/+1
|
* 2011-01-07 Ralf Corsepius <ralf.corsepius@rtems.org>Jeff Johnston2011-01-071-2/+2
| | | | | * libc/sys/rtems/crt0.c: Adjust free() and calloc() to match their public decls.
* 2011-01-05 Ralf Corsepius <ralf.corsepius@rtems.org>Jeff Johnston2011-01-051-0/+2
| | | | | * libc/stdio/open_memstream.c (internal_open_memstream_r): Don't limit c->max to 64*1024 on targets with SIZE_MAX < 64*1024.
* 2011-01-05 Ralf Corsepius <ralf.corsepius@rtems.org>Jeff Johnston2011-01-051-2/+2
| | | | * libc/xdr/xdr.c: Fix typos in #errors.
* 2011-01-05 Ralf Corsepius <ralf.corsepius@rtems.org>Jeff Johnston2011-01-052-0/+2
| | | | | * libc/xdr/xdr_private.h: Include <stdint.h> * libc/xdr/xdr_rec.c: Include limits.h
* 2011-01-05 Ralf Corsepius <ralf.corsepius@rtems.org>Jeff Johnston2011-01-052-4/+2
| | | | | * libc/Makefile.am (SUBDEFS): Remove redundant posix/stmp-def. * libc/Makefile.in: Regenerate.
* 2011-01-05 Ralf Corsepius <ralf.corsepius@rtems.org>Jeff Johnston2011-01-052-36/+3
| | | | | * libc/configure.in: Remove redundant posix_dir processing. * libc/configure: Regenerate.
* cygwin:Christopher Faylor2010-12-261-0/+2
| | | | | | | | | | | | * cygwin.din: Export program_invocation_name and program_invocation_short_name. * dcrt0.cc: Set program_invocation*name to correct values, based on argv[0]. * globals.cc (program_invocation_name): Define. (program_invocation_short_name): Ditto newlib: * libc/include/sys/errno.h (program_invocation_name): Declare. (program_invocation_short_name): Ditto.
* 2010-12-16 Jeff Johnston <jjohnstn@redhat.com>Jeff Johnston2010-12-16259-108814/+78871
| | | | | | | | | | | | | | | | | | | | * NEWS: Update with 1.19.0 info. * README: Ditto. * MAINTAINERS: Update. * acinclude.m4: Change version number to 1.19.0. * aclocal.m4: Regenerated. * configure: Ditto. * Makefile.am: Fix stmp-targ-include target. * Makefile.in: Regenerated. * doc/aclocal.m4: Ditto. * doc/configure: Ditto. * libc/*/aclocal.m4: Ditto. * libc/*/configure: Ditto. * libc/libc.texinfo: Ditto. * libm/*/aclocal.m4: Ditto. * libm/*/configure: Ditto. * libm/libm.texinfo: Ditto. * libc/sys/linux/shared.ld: Add VERS_1.19
* * include/sys/types.h: Add #if defined(__rtems__) aroundCorinna Vinschen2010-12-082-2/+13
| | | | | | | | pthread_attr_t.guardsize. * include/pthread.h: Add pthread_attr_setstack, pthread_attr_getstack, pthread_attr_getguardsize, pthread_attr_setguardsize. * include/sys/types.h (pthread_attr_t): Add guardsize.
* * libc/include/strings.h: Don't include locale.h.Corinna Vinschen2010-12-081-1/+0
|
* strings.h: avoid namespace pollutionEric Blake2010-12-081-1/+1
| | | | | * libc/include/strings.h: Don't declare removed functions when requesting POSIX 2008 compliance.
* 2010-12-07 Jeff Johnston <jjohnstn@redhat.com>Jeff Johnston2010-12-071-14/+22
| | | | | * libc/stdlib/strtod.c(_strtod_r): Fix code to handle case whereby _DOUBLE_IS_32BITS is set and DBL_DIGS is 6 instead of 15.
* 2010-12-07 Ralf Corsépius <ralf.corsepius@rtems.org>Jeff Johnston2010-12-071-0/+36
| | | | * libc/include/strings.h: New (split-out from string.h).
* * libc/include/math.h: Missing from previous checkin.Corinna Vinschen2010-12-031-5/+5
|