summaryrefslogtreecommitdiff
path: root/sysdeps
AgeCommit message (Collapse)Author
2004-11-15Update.cvs/fedora-glibc-20041116T0856Ulrich Drepper
2004-11-15 Jakub Jelinek <jakub@redhat.com> * posix/bug-regex24.c: Include string.h. * nis/nis_clone_obj.c (nis_clone_object): Rename out3 label to out2 and out2 to out. Remove out label. Formatting. 2004-11-15 Ulrich Drepper <drepper@redhat.com> * include/stdio.h: Do not mark __libc_message as noreturn. * sysdeps/unix/sysv/linux/libc_fatal.c (__libc_fatal): Add loop to fool gcc. Include <stdbool.h>. * sysdeps/posix/libc_fatal.c (__libc_fatal): Add loop to fool gcc. (__libc_message): Fix typo.
2004-11-13Update.Ulrich Drepper
* malloc/malloc.c (_int_free): Remove test for NULL parameter. (_int_realloc): Call _int_free only if memory parameter is not NULL.
2004-11-13Add new function __libc_message which performs the printing and simple ↵Ulrich Drepper
format string handling. The string is written to tty, stderr, syslog in this order, stopping after the first successful output.
2004-11-12Update.Ulrich Drepper
2004-11-12 Jakub Jelinek <jakub@redhat.com> * sysdeps/unix/sysv/linux/i386/setuid.c: Include linux/posix_types.h. * sysdeps/unix/sysv/linux/i386/setgid.c: Likewise. * sysdeps/unix/sysv/linux/i386/setreuid.c: Likewise. * sysdeps/unix/sysv/linux/i386/setregid.c: Likewise. * sysdeps/unix/sysv/linux/i386/setresuid.c: Likewise. * sysdeps/unix/sysv/linux/i386/setresgid.c: Likewise.
2004-11-12Update.Ulrich Drepper
2004-11-10 Jakub Jelinek <jakub@redhat.com> * sysdeps/unix/sysv/linux/setreuid.c: Remove sys/syscall.h, sys/types.h, linux/posix_types.h, sysdep.h and pthread-functions.h includes. Include setxid.h. Use INLINE_SETXID_SYSCALL macro instead of INLINE_SYSCALL, kill the HAVE_PTR__NPTL_SETXID guarded snippets. * sysdeps/unix/sysv/linux/setegid.c: Likewise. * sysdeps/unix/sysv/linux/setuid.c: Likewise. * sysdeps/unix/sysv/linux/seteuid.c: Likewise. * sysdeps/unix/sysv/linux/setgid.c: Likewise. * sysdeps/unix/sysv/linux/setresuid.c: Likewise. * sysdeps/unix/sysv/linux/setresgid.c: Likewise. * sysdeps/unix/sysv/linux/setregid.c: Likewise. * sysdeps/unix/sysv/linux/i386/setegid.c: Likewise. * sysdeps/unix/sysv/linux/i386/setreuid.c: Likewise. * sysdeps/unix/sysv/linux/i386/setuid.c: Likewise. * sysdeps/unix/sysv/linux/i386/seteuid.c: Likewise. * sysdeps/unix/sysv/linux/i386/setgid.c: Likewise. * sysdeps/unix/sysv/linux/i386/setresuid.c: Likewise. * sysdeps/unix/sysv/linux/i386/setresgid.c: Likewise. * sysdeps/unix/sysv/linux/i386/setregid.c: Likewise. * sysdeps/unix/sysv/linux/alpha/setreuid.c: Likewise. Formatting. Change signed int into int. * sysdeps/unix/sysv/linux/alpha/setresuid.c: Likewise. * sysdeps/unix/sysv/linux/alpha/setresgid.c: Likewise. * sysdeps/unix/sysv/linux/alpha/setregid.c: Likewise. * sysdeps/unix/sysv/linux/syscalls.list (setresuid, setresgid): Remove. * sysdeps/unix/setxid.h: New file. * Rules (binaries-static): Add xtests-static. * Makeconfig (run-program-prefix): Filter also xtests-static.
2004-11-12Remove sys/syscall.h, sys/types.h, linux/posix_types.h, sysdep.h and ↵Ulrich Drepper
pthread-functions.h includes. Include setxid.h. Use INLINE_SETXID_SYSCALL macro instead of INLINE_SYSCALL, kill the HAVE_PTR__NPTL_SETXID guarded snippets.
2004-11-11[BZ #542]Roland McGrath
2004-11-11 Simon Josefsson <jas@extundo.com> [BZ #542] * sysdeps/generic/strtok_r.c [HAVE_CONFIG_H]: Include config.h. [!_LIBC]: Include strtok_r.h (in gnulib), map __strtok_r to strtok_r and __rawmemchr to strch. (__strtok_r): Use C89 prototype. [weak_alias]: Move calls to libc_hidden_def and weak_alias into this #ifdef.
2004-11-10Update.Ulrich Drepper
2004-11-09 Jakub Jelinek <jakub@redhat.com> * posix/regcomp.c (calc_eclosure_iter): Don't access dfa->edests[node].elems[0] if dfa->edests[node].nelem == 0. * posix/rxspencer/tests: Add 5 new tests.
2004-11-10Update.Ulrich Drepper
2004-11-09 Ulrich Drepper <drepper@redhat.com> * sysdeps/unix/sysv/linux/ifaddrs.c: Determine sin6_scope_id field value correctly.
2004-11-082004-11-03 Marcus Brinkmann <marcus@gnu.org>Roland McGrath
* sysdeps/gnu/_G_config.h (_G_HAVE_MREMAP): Define symbol. * sysdeps/mach/hurd/_G_config.h: New file. * libio/fileops.c (mmap_remap_check) [__linux__]: Replaced with [_G_HAVE_MREMAP].
2004-11-06* sysdeps/gnu/errlist.c: Regenerated.Roland McGrath
2004-11-06* sysdeps/generic/ldsodefs.h (struct rtld_global_ro): DefineRoland McGrath
_dl_sysinfo_dso under [NEED_DL_SYSINFO_DSO] as well. * elf/rtld.c (dl_main): Set up GLRO(dl_sysinfo_dso) under [NEED_DL_SYSINFO_DSO] as well. * sysdeps/generic/dl-sysdep.c (_dl_show_auxv): Always include AT_SYSINFO and AT_SYSINFO_EHDR in name table. (_dl_sysdep_start) [NEED_DL_SYSINFO_DSO]: Match AT_SYSINFO_EHDR. * elf/dl-support.c (_dl_sysinfo_dso): Define also under [NEED_DL_SYSINFO_DSO]. (_dl_aux_init) [NEED_DL_SYSINFO || NEED_DL_SYSINFO_DSO]: Match AT_SYSINFO_EHDR and set GL(dl_sysinfo_dso). 2004-11-05 Roland McGrath <roland@redhat.com>
2004-11-04* sysdeps/unix/sysv/linux/x86_64/sys/procfs.h [__WORDSIZE == 32]Roland McGrath
(elf_fpxregset_t): New type. (struct elf_prpsinfo): If __WORDSIZE == 32, change pr_[ug]id type to unsigned short int. * sysdeps/unix/sysv/linux/x86_64/sys/user.h (struct user_fpregs_struct): Fix comment. * sysdeps/i386/fpu/bits/mathdef.h (float_t, double_t): If __FLOAT_EVAL_METHOD__ is defined and 0, typedef to float resp. double. * sysdeps/x86_64/fpu/bits/mathdef.h: Include bits/wordsize.h. (float_t, double_t): If -m32 and not -mfpmath=sse, typedef to long double. * sysdeps/x86_64/fpu/bits/fenv.h: Include bits/wordsize.h. (fenv_t): Remove __mxcsr field for -m32.
2004-11-04 * sysdeps/unix/sysv/linux/alpha/register-dump.h (regnames): Align. ↵Richard Henderson
(linefeed): Remove. (register_dump): Rewrite to generate into a flat buffer instead of into iovecs. 2004-11-04 Richard Henderson <rth@redhat.com> * sysdeps/unix/sysv/linux/alpha/register-dump.h (regnames): Align. (linefeed): Remove. (register_dump): Rewrite to generate into a flat buffer instead of into iovecs.
2004-11-03* sysdeps/generic/utime.c: Include <stddef.h>.Roland McGrath
2004-11-03* sysdeps/generic/sysconf.c: Include <grp.h> and <pwd.h>.Roland McGrath
2004-11-032004-11-03 Marcus Brinkmann <marcus@gnu.org>Roland McGrath
* sysdeps/generic/tempname.c (__path_search): Add missing argument TRY_TMPDIR.
2004-11-01 * sysdeps/unix/sysv/linux/alpha/setregid.c: New file. * ↵cvs/fedora-glibc-20041102T1153Richard Henderson
sysdeps/unix/sysv/linux/alpha/setresgid.c: New file. * sysdeps/unix/sysv/linux/alpha/setresuid.c: New file. * sysdeps/unix/sysv/linux/alpha/setreuid.c: New file. 2004-10-31 Mariusz Mazur <mmazur@kernel.pl> * sysdeps/unix/sysv/linux/alpha/setregid.c: New file. * sysdeps/unix/sysv/linux/alpha/setresgid.c: New file. * sysdeps/unix/sysv/linux/alpha/setresuid.c: New file. * sysdeps/unix/sysv/linux/alpha/setreuid.c: New file.
2004-10-30(elf_machine_rela) (elf_machine_rela_relative, elf_machine_lazy_rel): Mark ↵Andreas Schwab
auto instead of static.
2004-10-30Update.Ulrich Drepper
2004-10-30 Andreas Schwab <schwab@suse.de> * sysdeps/unix/sysv/linux/waitid.c: Include <stddef.h> for NULL. 2004-10-30 Ulrich Drepper <drepper@redhat.com> * malloc/malloc.c (_int_free): Use unique comments for the error cases.
2004-10-29* sysdeps/mach/hurd/i386/tls.h (_hurd_tls_fork): Use i386_thread_stateRoland McGrath
instead of machine_thread_state.
2004-10-282004-10-28 Roland McGrath <roland@redhat.com>Roland McGrath
* sysdeps/unix/sysv/linux/syscalls.list: Remove setaltroot.
2004-10-27Update.Ulrich Drepper
2004-10-27 Jakub Jelinek <jakub@redhat.com> * sysdeps/generic/glob.c (globfree): Clear gl_pathv after freeing it. * posix/Makefile: Add rules to build and run bug-glob2 test. * posix/bug-glob2.c: New test.
2004-10-27* sysdeps/mach/hurd/i386/tls.h (HURD_TLS_DESC_DECL): New macro.Roland McGrath
(_hurd_tls_init): Use it. (_hurd_tls_fork): New function. * sysdeps/mach/hurd/fork.c (__fork) [USE_TLS]: Call it.
2004-10-27* sysdeps/mach/hurd/i386/tls.h (_hurd_tls_init): Initialize TCB->tcb.Roland McGrath
2004-10-26* sysdeps/gnu/netinet/udp.h (struct udphdr): Use u_int16_tRoland McGrath
type instead of uint16_t. Formatting.
2004-10-26* sysdeps/unix/bsd/hp: Directory and all files removed.Roland McGrath
These are now in the ports repository. * sysdeps/unix/bsd/osf: Likewise. * sysdeps/unix/bsd/sequent: Likewise. * sysdeps/unix/bsd/sony: Likewise. * sysdeps/unix/bsd/ultrix4: Likewise. * sysdeps/unix/sysv/aix: Likewise. * sysdeps/unix/sysv/hpux: Likewise. * sysdeps/unix/sysv/irix4: Likewise. * sysdeps/unix/sysv/isc2.2: Likewise. * sysdeps/unix/sysv/minix: Likewise. * sysdeps/unix/sysv/sco3.2.4: Likewise. * sysdeps/unix/sysv/sco3.2: Likewise. * sysdeps/unix/sysv/sysv4: Likewise.
2004-10-262004-10-25 Roland McGrath <roland@frob.com>Roland McGrath
* configure.in (ASM_LINE_SEP): Move this setting to ... * sysdeps/hppa/configure.in: ... here, new file. * sysdeps/hppa/configure: New generated file. * configure: Regenerated.
2004-10-25Update.Ulrich Drepper
2004-10-25 Kaz Kojima <kkojima@rr.iij4u.or.jp> * sysdeps/sh/dl-machine.h: Include sysdep.h. (ELF_MACHINE_RUNTIME_TRAMPOLINE): Add CFI directives. (elf_machine_runtime_setup): Add always_inline attribute. (_dl_start_user): Pass the correct environ. (elf_machine_rela): Replace static inline by auto inline, add always_inline attribute. (elf_machine_rela_relative): Likewise. (elf_machine_lazy_rel): Likewise.
2004-10-24Ancient files moved to ports repositoryRoland McGrath
2004-10-24* sysdeps/mach/hurd/i386/tls.h (_hurd_tls_init): Don't return earlyRoland McGrath
after an RPC succeeds.
2004-10-23Moved tahoe files to ports repositoryRoland McGrath
* sysdeps/tahoe, sysdeps/unix/bsd/tahoe: Likewise.
2004-10-23Moved vax files to ports repositoryRoland McGrath
2004-10-23 Roland McGrath <roland@frob.com> * sysdeps/vax, sysdeps/unix/bsd/vax: Directories and all files removed. These are now in the ports repository.
2004-10-22Update.Ulrich Drepper
* debug/execinfo.h: Remove __THROW from backtrace prototype. 2004-10-22 Jakub Jelinek <jakub@redhat.com> * sysdeps/i386/Makefile (CFLAGS-backtrace.c): Add -fexceptions. * sysdeps/i386/backtrace.c: Include <bits/libc-lock.h>, <dlfcn.h>, <stdlib.h> and <unwind.h>. Remove <bp-checks.h> include. (struct trace_arg): New type. (unwind_backtrace, unwind_getip, unwind_getcfa, unwind_getgr): New fn pointers resp. macros. (init, backtrace_helper): New functions. (__backtrace): Rewritten to use _Unwind_Backtrace first and fall back to frame pointer walking. 2004-10-22 Ulrich Drepper <drepper@redhat.com>
2004-10-22Update.Ulrich Drepper
2004-10-22 Ulrich Drepper <drepper@redhat.com> * sysdeps/unix/sysv/linux/Versions: Things are still in flux, it seems. Undo last additions.
2004-10-20* manual/errno.texi (Error Codes): Add ENOKEY, EKEYEXPIRED,cvs/fedora-glibc-20041020T1016Roland McGrath
EKEYREVOKED, EKEYREJECTED. * sysdeps/unix/sysv/linux/Versions (libc: GLIBC_2.3.4): New errlist. * sysdeps/gnu/errlist.c: Regenerated * sysdeps/gnu/errlist-compat.awk: Don't bail if Versions gives a count higher than ERR_MAX reports. Instead, emit a #define ERR_MAX. * sysdeps/gnu/Makefile ($(objpfx)errlist-compat.h): New target. (generated): Add errlist-compat.h. * sysdeps/gnu/errlist.awk: Make output #include <errlist-compat.h> to define ERR_MAX and use that for table size.
2004-10-202004-10-20 Roland McGrath <roland@redhat.com>Roland McGrath
* sysdeps/gnu/errlist-compat.awk: Don't bail if Versions gives a count higher than ERR_MAX reports. Instead, emit a #define ERR_MAX. * sysdeps/gnu/Makefile ($(objpfx)errlist-compat.h): New target. (generated): Add errlist-compat.h. * sysdeps/gnu/errlist.awk: Make output #include <errlist-compat.h> to define ERR_MAX and use that for table size.
2004-10-20Update.Ulrich Drepper
2004-10-20 Ulrich Drepper <drepper@redhat.com> * sysdeps/unix/sysv/linux/syscalls.list: Add entries for setaltroot, key_add, key_request, and keyctl syscalls. * sysdeps/unix/sysv/linux/Versions: Export them.
2004-10-20Regenerated from ../sysdeps/gnu/errlist.awk ../manual/errno.texiUlrich Drepper
2004-10-202004-10-19 Roland McGrath <roland@frob.com>Roland McGrath
* sysdeps/mach/readonly-area.c: New file.
2004-10-20Regenerated from ../sysdeps/gnu/errlist.awk ../manual/errno.texiUlrich Drepper
2004-10-19Update.Ulrich Drepper
2004-10-19 Ulrich Drepper <drepper@redhat.com> * elf/Versions [ld, GLIBC_PRIVATE]: Add _dl_debug_state. * elf/dl-debug.c (_dl_debug_state): Add rtld_hidden_def. * sysdeps/generic/ldsodefs.h (_dl_debug_state): Don't maek as hidden but use rtld_hidden_proto.
2004-10-19Update.Ulrich Drepper
2004-10-19 Alfred M. Szmidt <ams@gnu.org> * sysdeps/generic/readonly-area.c (__readonly_str): Renamed to ... (__readonly_area): ... this.
2004-10-19Update.Ulrich Drepper
2004-10-18 Jakub Jelinek <jakub@redhat.com> * sysdeps/generic/strcpy_chk.c (__strcpy_chk): Speed up by checking destlen only every 4 bytes.
2004-10-18(__SYSCALL_CLOBBERS): Add "memory".Andreas Jaeger
2004-10-182004-10-15 Jakub Jelinek <jakub@redhat.com>Ulrich Drepper
* elf/dl-minimal.c (__chk_fail): New. Add rtld_hidden_def. * sysdeps/unix/sysv/linux/readonly-area.c: New file. * sysdeps/i386/i686/memmove.S (__memmove_chk): Add checking routine. * sysdeps/i386/i686/memcpy.S (__memcpy_chk): Likewise. * sysdeps/i386/i686/mempcpy.S (__mempcpy_chk): Likewise. * sysdeps/i386/i686/memset.S (__memset_chk): Likewise. * sysdeps/i386/i686/memmove-chk.S: New file. * sysdeps/i386/i686/memcpy-chk.S: Likewise. * sysdeps/i386/i686/mempcpy-chk.S: Likewise. * sysdeps/i386/i686/memset-chk.S: Likewise. * sysdeps/generic/strcat-chk.c (__strcat_chk): Don't __chk_fail if exactly fitting into buffer. * sysdeps/generic/strncat-chk.c (__strncat_chk): Likewise. * sysdeps/generic/readonly-area.c: New file. * sysdeps/generic/strncpy-chk.c (__strncpy_chk): Only test destlen once. * sysdeps/x86_64/memset.S (__memset_chk): Add checking routine. * sysdeps/x86_64/memcpy.S (__memcpy_chk): Likewise. * sysdeps/x86_64/mempcpy.S (__memcpy_chk): Define to __mempcpy_chk. * sysdeps/x86_64/memcpy-chk.S: New file. * sysdeps/x86_64/mempcpy-chk.S: Likewise. * sysdeps/x86_64/memset-chk.S: Likewise. * sysdeps/x86_64/strcpy-chk.S: Likewise. * sysdeps/x86_64/stpcpy-chk.S: Likewise. * argp/argp-xinl.c (__OPTIMIZE__): Define to 1 instead of nothing. * argp/argp-fs-xinl.c (__OPTIMIZE__): Likewise. * debug/tst-chk1.c: New test. * debug/tst-chk2.c: Likewise. * debug/tst-chk3.c: Likewise. * debug/test-strcpy_chk.c: Likewise. * debug/test-stpcpy_chk.c: Likewise. * debug/vsprintf_chk.c (__vsprintf_chk): If flags > 0, request _IO_FLAGS2_CHECK_PERCENT_N. Add libc_hidden_def. * debug/Makefile (routines): Add printf_chk, fprintf_chk, vprintf_chk, vfprintf_chk, gets_chk and readonly-area. (CFLAGS-*_chk.c): Set. (tests): Add tst-chk1, tst-chk2, tst-chk3, test-strcpy_chk and test-stpcpy_chk. * debug/vprintf_chk.c: New file. * debug/printf_chk.c: Likewise. * debug/vfprintf_chk.c: Likewise. * debug/fprintf_chk.c: Likewise. * debug/gets_chk.c: Likewise. * debug/chk_fail.c (__chk_fail): Add libc_hidden_def. * debug/snprintf_chk.c (__snprintf_chk): Fix order of arguments passed to __vsnprintf_chk. * debug/Versions (libc): Export __printf_chk, __fprintf_chk, __vprintf_chk, __vfprintf_chk and __gets_chk @GLIBC_2.3.4. * debug/vsnprintf_chk.c (__vsnprintf_chk): Don't call __vsnprintf, instead create a temporary file with _IO_strn_jumps jumptable. If flags > 0, request _IO_FLAGS2_CHECK_PERCENT_N. Add libc_hidden_def. * libio/Makefile (headers): Add bits/stdio2.h. * libio/stdio.h: Include <bits/stdio2.h> if __USE_FORTIFY_LEVEL. (sprintf, snprintf, vsprintf, vsnprintf): Remove defines. * libio/strfile.h (_IO_strnfile): New type. (_IO_strn_jumps): New extern. * libio/vsnprintf.c (_IO_strnfile): Remove. (_IO_strn_jumps): Remove static. * libio/bits/stdio2.h: New file. * libio/vswprintf.c (_IO_strnfile): Rename type to... (_IO_wstrnfile): ...this. Adjust all uses. * libio/libio.h (_IO_FLAGS2_CHECK_PERCENT_N): Define. * stdio-common/vfprintf.c (STR_LEN): Define. (vfprintf): Add readonly_format variable. Handle _IO_FLAGS2_CHECK_PERCENT_N. (buffered_vfprintf): Copy _flags2. * include/stdio.h (__sprintf_chk, __snprintf_chk, __vsprintf_chk, __vsnprintf_chk, __printf_chk, __fprintf_chk, __vprintf_chk, __vfprintf_chk): New prototypes. (__vsprintf_chk, __vsnprintf_chk): Add libc_hidden_proto. * include/string.h (__memcpy_chk, __memmove_chk, __mempcpy_chk, __memset_chk, __strcpy_chk, __stpcpy_chk, __strncpy_chk, __strcat_chk, __strncat_chk): New prototypes. * include/bits/string3.h: New file. * include/sys/cdefs.h (__chk_fail): Add libc_hidden_proto and rtld_hidden_proto. * string/Makefile (headers): Add bits/string3.h. * string/bits/string3.h (bcopy, bzero): New defines. (memset, memcpy, memmove, strcpy, strncpy, strcat, strncat): Change macros so that inlines are used only if unknown destination size or side-effects in destination argument. (mempcpy, stpcpy): Likewise. Protect with #ifdef __USE_GNU. 2004-09-16 Ulrich Drepper <drepper@redhat.com> * debug/Makefile (routines): Add *_chk. * debug/Versions (libc): Export __chk_fail, __memcpy_chk, __memmove_chk, __mempcpy_chk, __memset_chk, __stpcpy_chk, __strcat_chk, __strcpy_chk, __strncat_chk, __strncpy_chk, __sprintf_chk, __vsprintf_chk, __snprintf_chk, __vsnprintf_chk @GLIBC_2.3.4. * debug/chk_fail.c: New file. * debug/snprintf_chk.c: Likewise. * debug/sprintf_chk.c: Likewise. * debug/vsnprintf_chk.c: Likewise. * debug/vsprintf_chk.c: Likewise. * include/features.h (_FORTIFY_SOURCE): Document, handle. (__USE_FORTIFY_LEVEL): Define. (__GNUC_PREREQ): Move to earlier location. * include/sys/cdefs.h (__chk_fail): New prototype. * libio/bits/stdio.h (sprintf, vsprintf, snprintf, vsnprintf): Define if __USE_FORTIFY_LEVEL. * misc/sys/cdefs.h (__bos, __bos0): Define. * string/string.h: Include <bits/string3.h> if __USE_FORTIFY_LEVEL. * bits/string/string3.h: New header. * sysdeps/generic/memcpy_chk.c: New file. * sysdeps/generic/memmove_chk.c: Likewise. * sysdeps/generic/mempcpy_chk.c: Likewise. * sysdeps/generic/memset_chk.c: Likewise. * sysdeps/generic/stpcpy_chk.c: Likewise. * sysdeps/generic/strcat_chk.c: Likewise. * sysdeps/generic/strcpy_chk.c: Likewise. * sysdeps/generic/strncat_chk.c: Likewise. * sysdeps/generic/strncpy_chk.c: Likewise. 2004-10-15 Jakub Jelinek <jakub@redhat.com> * elf/dl-minimal.c (__chk_fail): New. Add rtld_hidden_def. * sysdeps/unix/sysv/linux/readonly-area.c: New file. * sysdeps/i386/i686/memmove.S (__memmove_chk): Add checking routine. * sysdeps/i386/i686/memcpy.S (__memcpy_chk): Likewise. * sysdeps/i386/i686/mempcpy.S (__mempcpy_chk): Likewise. * sysdeps/i386/i686/memset.S (__memset_chk): Likewise. * sysdeps/i386/i686/memmove-chk.S: New file. * sysdeps/i386/i686/memcpy-chk.S: Likewise. * sysdeps/i386/i686/mempcpy-chk.S: Likewise. * sysdeps/i386/i686/memset-chk.S: Likewise. * sysdeps/generic/strcat-chk.c (__strcat_chk): Don't __chk_fail if exactly fitting into buffer. * sysdeps/generic/strncat-chk.c (__strncat_chk): Likewise. * sysdeps/generic/readonly-area.c: New file. * sysdeps/generic/strncpy-chk.c (__strncpy_chk): Only test destlen once. * sysdeps/x86_64/memset.S (__memset_chk): Add checking routine. * sysdeps/x86_64/memcpy.S (__memcpy_chk): Likewise. * sysdeps/x86_64/mempcpy.S (__memcpy_chk): Define to __mempcpy_chk. * sysdeps/x86_64/memcpy-chk.S: New file. * sysdeps/x86_64/mempcpy-chk.S: Likewise. * sysdeps/x86_64/memset-chk.S: Likewise. * sysdeps/x86_64/strcpy-chk.S: Likewise. * sysdeps/x86_64/stpcpy-chk.S: Likewise. * argp/argp-xinl.c (__OPTIMIZE__): Define to 1 instead of nothing. * argp/argp-fs-xinl.c (__OPTIMIZE__): Likewise. * debug/tst-chk1.c: New test. * debug/tst-chk2.c: Likewise. * debug/tst-chk3.c: Likewise. * debug/test-strcpy_chk.c: Likewise. * debug/test-stpcpy_chk.c: Likewise. * debug/vsprintf_chk.c (__vsprintf_chk): If flags > 0, request _IO_FLAGS2_CHECK_PERCENT_N. Add libc_hidden_def. * debug/Makefile (routines): Add printf_chk, fprintf_chk, vprintf_chk, vfprintf_chk, gets_chk and readonly-area. (CFLAGS-*_chk.c): Set. (tests): Add tst-chk1, tst-chk2, tst-chk3, test-strcpy_chk and test-stpcpy_chk. * debug/vprintf_chk.c: New file. * debug/printf_chk.c: Likewise. * debug/vfprintf_chk.c: Likewise. * debug/fprintf_chk.c: Likewise. * debug/gets_chk.c: Likewise. * debug/chk_fail.c (__chk_fail): Add libc_hidden_def. * debug/snprintf_chk.c (__snprintf_chk): Fix order of arguments passed to __vsnprintf_chk. * debug/Versions (libc): Export __printf_chk, __fprintf_chk, __vprintf_chk, __vfprintf_chk and __gets_chk @GLIBC_2.3.4. * debug/vsnprintf_chk.c (__vsnprintf_chk): Don't call __vsnprintf, instead create a temporary file with _IO_strn_jumps jumptable. If flags > 0, request _IO_FLAGS2_CHECK_PERCENT_N. Add libc_hidden_def. * libio/Makefile (headers): Add bits/stdio2.h. * libio/stdio.h: Include <bits/stdio2.h> if __USE_FORTIFY_LEVEL. (sprintf, snprintf, vsprintf, vsnprintf): Remove defines. * libio/strfile.h (_IO_strnfile): New type. (_IO_strn_jumps): New extern. * libio/vsnprintf.c (_IO_strnfile): Remove. (_IO_strn_jumps): Remove static. * libio/bits/stdio2.h: New file. * libio/vswprintf.c (_IO_strnfile): Rename type to... (_IO_wstrnfile): ...this. Adjust all uses. * libio/libio.h (_IO_FLAGS2_CHECK_PERCENT_N): Define. * stdio-common/vfprintf.c (STR_LEN): Define. (vfprintf): Add readonly_format variable. Handle _IO_FLAGS2_CHECK_PERCENT_N. (buffered_vfprintf): Copy _flags2. * include/stdio.h (__sprintf_chk, __snprintf_chk, __vsprintf_chk, __vsnprintf_chk, __printf_chk, __fprintf_chk, __vprintf_chk, __vfprintf_chk): New prototypes. (__vsprintf_chk, __vsnprintf_chk): Add libc_hidden_proto. * include/string.h (__memcpy_chk, __memmove_chk, __mempcpy_chk, __memset_chk, __strcpy_chk, __stpcpy_chk, __strncpy_chk, __strcat_chk, __strncat_chk): New prototypes. * include/bits/string3.h: New file. * include/sys/cdefs.h (__chk_fail): Add libc_hidden_proto and rtld_hidden_proto. * string/Makefile (headers): Add bits/string3.h. * string/bits/string3.h (bcopy, bzero): New defines. (memset, memcpy, memmove, strcpy, strncpy, strcat, strncat): Change macros so that inlines are used only if unknown destination size or side-effects in destination argument. (mempcpy, stpcpy): Likewise. Protect with #ifdef __USE_GNU. 2004-09-16 Ulrich Drepper <drepper@redhat.com> * debug/Makefile (routines): Add *_chk. * debug/Versions (libc): Export __chk_fail, __memcpy_chk, __memmove_chk, __mempcpy_chk, __memset_chk, __stpcpy_chk, __strcat_chk, __strcpy_chk, __strncat_chk, __strncpy_chk, __sprintf_chk, __vsprintf_chk, __snprintf_chk, __vsnprintf_chk @GLIBC_2.3.4. * debug/chk_fail.c: New file. * debug/snprintf_chk.c: Likewise. * debug/sprintf_chk.c: Likewise. * debug/vsnprintf_chk.c: Likewise. * debug/vsprintf_chk.c: Likewise. * include/features.h (_FORTIFY_SOURCE): Document, handle. (__USE_FORTIFY_LEVEL): Define. (__GNUC_PREREQ): Move to earlier location. * include/sys/cdefs.h (__chk_fail): New prototype. * libio/bits/stdio.h (sprintf, vsprintf, snprintf, vsnprintf): Define if __USE_FORTIFY_LEVEL. * misc/sys/cdefs.h (__bos, __bos0): Define. * string/string.h: Include <bits/string3.h> if __USE_FORTIFY_LEVEL. * bits/string/string3.h: New header. * sysdeps/generic/memcpy_chk.c: New file. * sysdeps/generic/memmove_chk.c: Likewise. * sysdeps/generic/mempcpy_chk.c: Likewise. * sysdeps/generic/memset_chk.c: Likewise. * sysdeps/generic/stpcpy_chk.c: Likewise. * sysdeps/generic/strcat_chk.c: Likewise. * sysdeps/generic/strcpy_chk.c: Likewise. * sysdeps/generic/strncat_chk.c: Likewise. * sysdeps/generic/strncpy_chk.c: Likewise.
2004-10-172004-10-16 Alfred M. Szmidt <ams@kemisten.nu>Roland McGrath
* sysdeps/mach/hurd/Makefile (link-libc-static): Use `$(static-gnulib') instead of `$(gnulib)'.
2004-10-15Update.Ulrich Drepper
2004-10-15 Jakub Jelinek <jakub@redhat.com> * sysdeps/unix/sysv/linux/i386/sysdep.h (PUSHARGS_6, DOARGS_6, POPARGS_6, _PUSHARGS_6, _DOARGS_6, _POPARGS_6): Define. * sysdeps/unix/sysv/linux/i386/syscall.S (syscall): Handle 6 argument syscalls.
2004-10-15 * sysdeps/unix/sysv/linux/alpha/register-dump.h: New file. * ↵Richard Henderson
sysdeps/unix/sysv/linux/alpha/sigcontextinfo.h (SIGCONTEXT): Add _code argument, pass sigcontext by pointer. (SIGCONTEXT_EXTRA_ARGS): Likewise. (GET_PC, GET_FRAME, GET_STACK): Expect ctx as pointer. 2004-10-15 Richard Henderson <rth@redhat.com> * sysdeps/unix/sysv/linux/alpha/register-dump.h: New file. * sysdeps/unix/sysv/linux/alpha/sigcontextinfo.h (SIGCONTEXT): Add _code argument, pass sigcontext by pointer. (SIGCONTEXT_EXTRA_ARGS): Likewise. (GET_PC, GET_FRAME, GET_STACK): Expect ctx as pointer.
2004-10-15 * sysdeps/unix/sysv/linux/adjtime.c (ADJTIME): Use prototype ↵Richard Henderson
style definition. * sysdeps/unix/sysv/linux/alpha/adjtime.c (ADJTIME): If __ASSUME_TIMEVAL64, define __adjtime directly rather than via strong_alias. 2004-10-14 Richard Henderson <rth@redhat.com> * sysdeps/alpha/dl-machine.h (elf_machine_rela, elf_machine_rela_relative, elf_machine_lazy_rel): Mark auto instead of static. * sysdeps/unix/sysv/linux/adjtime.c (ADJTIME): Use prototype style definition. * sysdeps/unix/sysv/linux/alpha/adjtime.c (ADJTIME): If __ASSUME_TIMEVAL64, define __adjtime directly rather than via strong_alias.