[BZ #2751]
[glibc.git] / ChangeLog
blob2adc7bb44f9f1e5afd4fc44767971d55d3213c01
1 2006-05-15  Mike Frysinger  <vapier@gentoo.org>
3         [BZ #2751]
4         * string/strchr.c: Add cast to avoid warning.
6 2006-08-21  Ulrich Drepper  <drepper@redhat.com>
8         * malloc/malloc.c (DEFAULT_MMAP_THRESHOLD_MAX): For 32-bit
9         platforms define as 512K.  For 64-bit platforms as 32MB.  The lower
10         limit is needed to avoid the exploding of the address space
11         requirement for secondary heaps.
12         * malloc/arena.c (HEAP_MAX_SIZE): Define using
13         DEFAULT_MMAP_THRESHOLD_MAX if it is defined.
15 2006-07-30  Joseph S. Myers  <joseph@codesourcery.com>
17         [BZ #3018]
18         * Makerules (depfiles): Handle extra-test-objs the same as
19         extra-objs.
20         (common-mostlyclean): Likewise.
21         * dlfcn/Makefile (extra-objs): Add modules to extra-test-objs
22         instead.
23         * elf/Makefile (extra-objs): Likewise.
24         * stdlib/Makefile (extra-objs): Likewise.
26 2006-08-14  Eric Blake  <ebb9@byu.net>
28         [BZ #3044]
29         * misc/error.h: Assume C89 or better.
30         * misc/error.c: Likewise.
32 2006-08-21  Ulrich Drepper  <drepper@redhat.com>
34         [BZ #3040]
35         * sysdeps/unix/sysv/linux/openat.c: Fix compilation if
36         __ASSUME_ATFCTS is defined.
38 2006-08-19  Ulrich Drepper  <drepper@redhat.com>
40         * malloc/malloc.c (_int_malloc): Limit number of unsorted blocks
41         to sort in each call.
43         * nis/nss_nis/nis-service.c (internal_nis_getservent_r): . If map
44         is empty simply return and use next service.
45         * nis/nss_nis/nis-rpc.c (internal_nis_getrpcent_r): Likewise.
47         * locale/programs/charmap.c (charmap_read): Add new parameter.  It
48         tells us when not finding a charmap file is an error.
49         * locale/programs/charmap.h: Adjust charmap_read prototype.
50         * iconv/iconv_prog.c (main): Tell charmap_read it's no error if we
51         cannot find a charmap.
52         * locale/programs/localedef.c (main): Adjust charmap_read call.
54 2006-08-15  Jakub Jelinek  <jakub@redhat.com>
56         * sysdeps/unix/sysv/linux/sparc/sparc64/pause.c: Use
57         sysdeps/posix/pause.c implementation instead.
59 2006-08-09  Jakub Jelinek  <jakub@redhat.com>
61         * sysdeps/unix/nice.c (nice): Transform EACCES errno from setpriority
62         to EPERM.
64 2006-08-13  Andreas Schwab  <schwab@suse.de>
66         * sysdeps/powerpc/powerpc32/dl-trampoline.S (_dl_runtime_resolve):
67         Don't clobber caller's LRSAVE.
68         (_dl_prof_resolve): Likewise.
70 2006-08-14  Ulrich Drepper  <drepper@redhat.com>
72         [BZ #1996]
73         * libio/memstream.c (open_memstream): Allocate initial buffer with
74         calloc.
75         * libio/wmemstream.c (open_wmemstream): Likewise.
76         * libio/strops.c: Pretty printing.
77         (_IO_str_overflow): Clear uninitialized part of the new buffer.
78         (enlarge_userbuf): New function.
79         (_IO_str_seekoff): Call it if seek position is larger than current
80         buffer.
81         * libio/wstrops.c: Likewise.
82         * libio/vasprintf.c: Add comment as to why we do not have to use
83         calloc instead of malloc to allocate initial buffer.
84         * libio/Makefile (tests): Add bug-memstream1 and bug-wmemstream1.
85         * libio/bug-memstream1.c: New file.
86         * libio/bug-wmemstream1.c: New file.
88 2006-08-13  Ulrich Drepper  <drepper@redhat.com>
90         * libio/wstrops.c: Remove dead macro definitions and comments.
91         * libio/strops.c: Likewise.
93         [BZ #2764]
94         * login/utmpname.c (__utmpname): Remove unnecessary test.
96 2006-06-08  Joseph Myers  <jsm28@gcc.gnu.org>
98         [BZ #2832]
99         * math/gen-libm-test.pl (clean_up_number): Do not remove trailing
100         0s from integers.
102 2006-08-13  Ulrich Drepper  <drepper@redhat.com>
104         [BZ #2987]
105         * sysdeps/unix/sysv/linux/clock_settime.c: Add code to use syscall
106         for CPU clocks.
107         * sysdeps/unix/clock_settime.c: Add support for platform-specific
108         setting of CPU clocks.
110 2006-06-23  Paul Eggert  <eggert@cs.ucla.edu>
112         [BZ #2841]
113         * sysdeps/generic/stdint.h (UINT8_C, UINT16_C): Don't append 'U',
114         since C99 requires the result to promote to 'int' when uint_least8_t
115         and uint_least16_t promote to 'int'.
117 2006-08-12  Ulrich Drepper  <drepper@redhat.com>
119         [BZ #3013]
120         * locale/programs/ld-ctype.c (ctype_output): Adjust alignments, fix
121         lenght of one output field, correct bitmask creation.
122         * locale/programs/ld-time.c: Add alignment.
124         [BZ #2997]
125         * misc/error.c: Add space between program name and message if file
126         name is missing.
128 2006-08-03  Eric Blake  <ebb9@byu.net>
130         [BZ #2998]
131         * misc/error.c (error_tail) [_LIBC]: Avoid invalid free.
133 2006-08-09  Ulrich Drepper  <drepper@redhat.com>
135         * malloc/memusagestat.c: Silence warnings.
137         * malloc/malloc.c: Dynamically size mmap treshold if the program
138         frees mmaped blocks.
139         Patch by Valerie Henson and Arjan van de Ven.
141 2006-08-08  Jakub Jelinek  <jakub@redhat.com>
143         * sysdeps/unix/sysv/linux/ia64/bits/fcntl.h (O_DIRECT): Protect with
144         __USE_GNU.
146         * stdlib/strtol_l.c (__strtol_ul_max_tab, __strtol_ul_rem_tab,
147         __strtol_ull_max_tab, __strtol_ull_rem_tab): Declare.
148         (DEF): Don't put the var into .gnu.linkonce.r.* section.
149         Only provide var definitions in strtol_l (or for *ull*
150         in strtoll_l).
152         * stdio-common/bug16.c (tests): New array.
153         (do_tests): Allow the first hexadecimal digit
154         to be 1, 2, 4 or 8.  Do 3 additional tests.
156         * sysdeps/s390/fpu/libm-test-ulps: Update.
158         * sysdeps/unix/sysv/linux/s390/s390-32/fchownat.c (fchownat): Use
159         fchownat syscall if available.
160         * sysdeps/unix/sysv/linux/powerpc/fchownat.c (fchownat): Likewise.
161         * sysdeps/unix/sysv/linux/sh/fchownat.c (fchownat): Likewise.
162         * sysdeps/unix/sysv/linux/i386/fchownat.c (fchownat): Likewise.
164 2006-08-07  Ulrich Drepper  <drepper@redhat.com>
166         * nis/nis_xdr.c: Avoid some function calls.
168 2006-08-07  Jakub Jelinek  <jakub@redhat.com>
169             Ulrich Drepper  <drepper@redhat.com>
171         * nis/nis_call.c (rec_dirsearch) [case LOWER_NAME]: Don't take
172         short cut if only one name component is stripped away.
174 2006-08-07  Ulrich Drepper  <drepper@redhat.com>
176         * nis/nis_call.c: Minor cleanups throughout.
177         (rec_dirsearch) [case HIGHER_NAME]: Correctly size ndomain array.
178         (first_shoot): Add search_parent_first parameter.  Only if it is set
179         search parent server first.
180         If directory for table found through cold start cache is not the same
181         as referenced in the cache, don't use it.
182         (__nisfind_server): Take additional parameter.  Pass it on to
183         first_shoot.
184         (__prepare_niscall): Adjust __nisfind_server call.
185         * nis/rpcsvc/nislib.h: Adjust __nisfind_server prototype.
186         * nis/nis_table.c: Adjust __nisfind_server call.
187         * nis/nis_lookup.c: Likewise.
188         (nis_lookup): Don't loop endlessly if name is reduced to ".".
190 2006-08-03  Ulrich Drepper  <drepper@redhat.com>
192         [BZ #2182]
193         * math/s_cacosh.c: Return values from positive branch.
194         * math/s_cacoshf.c: Likewise.
195         * math/s_cacoshl.c: Likewise.
197         [BZ #2883]
198         * sysvipc/sys/msg.h: Change return value to ssize_t.
199         * sysdeps/unix/sysv/linux/msgrcv.c: Likewise.
200         * sysvipc/msgrcv.c: Likewise.
201         * include/sys/msg.h: Likewise.
203         * grp/initgroups.c (internal_getgrouplist): Remove unnecessary
204         test introduced in patch for bz #661.
205         (getgrouplist): Simplify code a bit.  Don't allocate one additional
206         element for NEWGROUPS.
208         [BZ #2908]
209         * stdio-common/printf_fphex.c (__printf_fphex): When rounding up
210         'f', use '1' as leading digit not '\1'.
211         * stdio-common/Makefile (tests): Add bug16.
212         * stdio-common/bug16.c: New file.
214         [BZ #2914]
215         * sysdeps/unix/sysv/linux/gethostid.c: Don't define OLD_HOSTIDFILE
216         and don't try to open it.  The patch introducing the macro
217         contained a bug and used the same file name as the new file
218         instead of using /var/adm/hostid.  Nobody complaint so I'm taking
219         this out completely.
221         [BZ #2926]
222         * assert/assert.h: Move cast to void inside ?: to quiet gcc.
223         Patch by Jerry James <Jerry.James@usu.edu>.
225         * rt/Makefile (tests): Add tst-clock2.
226         * rt/tst-clock2.c: New file.
228         [BZ #2978]
229         * resolv/gai_notify.c (__gai_notify_only): Copy memory for thread
230         function and its parameters and pass it to new thread.
231         (__gai_notify): Add support for alternative waiting for completion.
232         * resolv/gai_suspend.c (gai_suspend): Add support for alternative
233         waiting for completion.
234         * resolv/getaddrinfo_a.c: Likewise.
235         * resolv/gai_misc.h (struct waitlist): Don't add cond if alternative
236         waiting for completion is used.
237         * resolv/gai_misc.c: Allow overwriting code to start helper thread.
238         * resolv/gai_cancel.c: Include <gai_misc.h> not "gai_misc.h".
239         * resolv/gai_error.c: Likewise.
240         * resolv/gai_sigqueue.c: Likewise.
242 2006-08-02  Thomas Schwinge  <tschwinge@gnu.org>
244         * hurd/getdport.c (__getdport): Don't return EBADF; instead set
245         errno to EBADF and return MACH_PORT_NULL.
247 2006-06-23  Joseph Myers  <joseph@codesourcery.com>
249         [BZ #2980]
250         * posix/Makefile (CFLAGS-waitid.c): Add -fasynchronous-unwind-tables.
252 2006-08-02  Ulrich Drepper  <drepper@redhat.com>
254         * elf/dl-addr.c (_dl_addr): If GNU-style hash tables are present,
255         walk them instead of the symbol table.
257 2006-08-01  Ulrich Drepper  <drepper@redhat.com>
259         [BZ #2098]
260         * nscd/initgrcache.c (addinitgroupsX): Judge successful lookups by
261         status of NSS calls, not the number of returned entries.
263         * sysdeps/unix/sysv/linux/syscalls.list: Remove add_key,
264         request_key, keyctl.
266 2006-07-31  Ulrich Drepper  <drepper@redhat.com>
268         * sysdeps/unix/sysv/linux/dl-osinfo.h: Remove unnecessary include.
270 2006-07-16  Jeff Bailey  <jbailey@ubuntu.com>
272         * elf/tst-auditmod1.c: Fix typo in #error.
274 2006-07-31  Ulrich Drepper  <drepper@redhat.com>
276         * elf/tst-auditmod1.c: Remove code for unsupported architectures.
278         * iconvdata/run-iconv-test.sh: Run cmp in C locale.
280 2006-07-20  Adam Nemet  <anemet@caviumnetworks.com>
282         * stdlib/test-canon.c (do_test): Close fd before unlinking file so
283         that the directory is empty even on non-POSIX filesystems.
285 2006-07-31  Ulrich Drepper  <drepper@redhat.com>
287         * elf/dl-open.c (dl_open_worker): Add branch prediction.
289         * nis/nss_compat/compat-grp.c: Avoid unnecessary setgrent calls into
290         the backend NSS module.  If backend setgrent call failed, don't have
291         internal_setgrent fail.  Just remember this until it is needed.
292         * nis/nss_compat/compat-pwd.c: Likewise.
293         * nis/nss_compat/compat-spwd.c: Likewise.
295 2006-07-30  Roland McGrath  <roland@redhat.com>
297         * sysdeps/unix/sysv/linux/ia64/sigsuspend.c: File removed.
298         * sysdeps/unix/sysv/linux/x86_64/sigsuspend.c: File removed.
299         * sysdeps/unix/sysv/linux/s390/s390-64/sigsuspend.c: File removed.
300         * sysdeps/unix/sysv/linux/sparc/sparc64/sigsuspend.c: File removed.
302         * sysdeps/unix/sysv/linux/not-cancel.h (pause_not_cancel): New macro.
303         (nanosleep_not_cancel): New macro.
304         (sigsuspend_not_cancel): new macro.
305         * sysdeps/unix/sysv/linux/sigsuspend.c [__ASSUME_REALTIME_SIGNALS]
306         (do_sigsuspend): Define as inline.
307         (__sigsuspend): Always use do_sigsuspend.
308         [! NO_CANCELLATION] (__sigsuspend_nocancel): New function.
309         * include/signal.h: Declare __sigsuspend_nocancel.
310         * sysdeps/posix/pause.c
311         [! NO_CANCELLATION] (__pause_nocancel): New function.
313         * include/unistd.h (__pause_nocancel): Add attribute_hidden.
314         * include/time.h (__nanosleep_nocancel): Likewise.
316 2006-07-30  Ulrich Drepper  <drepper@redhat.com>
318         * locale/programs/localedef.c (add_to_readlist): Rename local
319         variables to avoid confusion.
321         * locale/programs/charmap.c (charmap_read): Emit error message if
322         charmap couldn't be found or read.
324 2006-07-28  Ulrich Drepper  <drepper@redhat.com>
326         * sysdeps/unix/sysv/linux/kernel-features.h: Define
327         __ASSUME_FUTEX_LOCK_PI.
328         * include/time.h: Declare __nanosleep_nocancel.
329         * include/unistd.h: Declare __pause_nocancel.
331         * dlfcn/Makefile (LDLIBS-bug-atexit3-lib.so): Use this instead of
332         LDFLAGS.  Add -lgcc_eh and libc_nonshared (again) to make sure we
333         get the __stack_chk_fail_local definition when it's needed.
335 2006-07-26  Ulrich Drepper  <drepper@redhat.com>
337         * dlfcn/Makefile: Add rules to build and run bug-atexit3.
338         * dlfcn/bug-atexit3.c: New file.
339         * dlfcn/bug-atexit3-lib.cc: New file.
341         * dlfcn/dlmopen.c (dlmopen_doit): Don't allow RTLD_GLOBAL to be
342         used when the namespace is not the base namespace.
344 2006-07-26  Gavin Romig-Koch  <gavin@redhat.com>
346         * stdlib/cxa_atexit.c (__new_exitfn_called): New variable.
347         (__new_exitfn): Bump it in every successful call.
348         * stdlib/cxa_finalize.c (__cxa_finalize): If destructor registered
349         more exit handlers, call them right away.
350         * stdlib/exit.h: Declare __new_exitfn_called.
352 2006-07-25  Ulrich Drepper  <drepper@redhat.com>
354         * stdlib/cxa_finalize.c (__cxa_finalize): Fix race condition when
355         calling registered handler.
357         * sysdeps/unix/sysv/linux/sparc/bits/fcntl.h: Fix comment.
358         * sysdeps/unix/sysv/linux/ia64/bits/fcntl.h: Likewise.
359         * sysdeps/unix/sysv/linux/sh/bits/fcntl.h: Likewise.
360         * sysdeps/unix/sysv/linux/i386/bits/fcntl.h: Likewise.
361         * sysdeps/unix/sysv/linux/s390/bits/fcntl.h: Likewise.
362         * sysdeps/unix/sysv/linux/x86_64/bits/fcntl.h: Likewise.
363         * sysdeps/unix/sysv/linux/alpha/bits/fcntl.h: Likewise.
364         * sysdeps/unix/sysv/linux/powerpc/bits/fcntl.h: Likewise.
366 2006-07-10  Ulrich Drepper  <drepper@redhat.com>
368         * elf/dl-lookup.c (dl_new_hash): New functions.
369         (_dl_lookup_symbol_x): Rename hash to old_hash and don't compute
370         value here.  Compute new-style hash value.  Pass new hash value
371         and reference to variable with the old value to do_lookup_x.
372         (_dl_setup_hash): If DT_GNU_HASH is defined, use it and not
373         old-style hash table.
374         (_dl_debug_bindings): Pass new hash value and reference to variable
375         with the old value to do_lookup_x.
376         * elf/do-lookup.h (do_lookup_x): Accept additional parameter with
377         new-style hash value and change old-style hash value parameter to
378         be a reference.  Reoganize functions to determine whether
379         new-style hash table is available.  Only fall back on old-style
380         table.  If old-style hash value is needed, compute it here.
381         * elf/dynamic-link.h (elf_get_dynamic_info): Relocate DT_GNU_HASH
382         entry.
383         * elf/elf.h: Define SHT_GNU_HASH, DT_GNU_HASH, DT_TLSDEC_PLT,
384         DT_TLSDEC_GOT.  Adjust DT_ADDRNUM.
385         * include/link.h (struct link_map): Add l_gnu_bitmask_idxbits,
386         l_gnu_shift, l_gnu_bitmask, l_gnu_buckets and l_gnu_chain_zero.
387         * Makeconfig: If linker supports --hash-style option add it to all
388         linker command lines to build DSOs.
389         * config.make.in: Define have-hash-style.
390         * configure.in: Test whether linker supports --hash-style option.
392         * elf/dl-misc.c (_dl_name_match_p): Make MAP parameter const.
393         * sysdeps/generic/ldsodefs.h: Adjust prototype.
395 2006-06-27  Ulrich Drepper  <drepper@redhat.com>
397         * elf/dl-load.c (open_path): Fix test to determine whether DSO is
398         auditing.
400         * elf/dl-load.c (_dl_map_object): Try harder to avoid looking at
401         RPATH of main map twice.
403 2006-06-22  Ulrich Drepper  <drepper@redhat.com>
405         * intl/dcigettext.c (DCIGETTEXT): If _nl_find_msg returns -1 don't
406         look further, return original strings.
407         (_nl_find_msg): Do not return found translation if the conversion
408         failed.  Either signal the string is unusable or that something went
409         wrong and the original should be used.
411 2006-06-21  Ulrich Drepper  <drepper@redhat.com>
413         * string/_strerror.c (__strerror_r): Add __builtin_expect.
415 2006-06-14  Jakub Jelinek  <jakub@redhat.com>
417         [BZ #2766]
418         * misc/insremque.c (insque): Handle prev == NULL.
419         * misc/Makefile (tests): Add tst-insremque.
420         * misc/tst-insremque.c: New test.
422 2006-06-17  Ulrich Drepper  <drepper@redhat.com>
424         [BZ #2792]
425         * elf/dl-deps.c (expand_dst): Rename __cnt variable to not
426         conflict with DL_DST_REQUIRED.
428 2006-06-16  Ulrich Drepper  <drepper@redhat.com>
430         * nis/nis_subr.c (nis_getnames): Fix the implementation to better
431         match what Solaris does.
433 2006-06-04  Ulrich Drepper  <drepper@redhat.com>
435         * sysdeps/posix/spawni.c (__spawni): Use local_seteuid and
436         local_setegid instead of seteuid and setegid.
437         * sysdeps/generic/local-setxid.h: New file.
438         * sysdeps/unix/sysv/linux/local-setxid.h: New file.
440         * sysdeps/posix/spawni.c (__spawni): Use non-cancelable interfaces.
442         * string/Makefile (tests): Add bug-envz1.
443         * string/bug-envz1.c: New file.
445 2006-06-02  Jakub Jelinek  <jakub@redhat.com>
447         * posix/regex_internal.c (re_string_skip_chars): If no character has
448         been converted at all, set *last_wc to WEOF.  If mbrtowc failed, set wc
449         to the byte which couldn't be converted.
450         (re_string_reconstruct): Don't clear valid_raw_len before calling
451         re_string_skip_chars.  If wc is WEOF after re_string_skip_chars, set
452         tip_context using re_string_context_at.
453         * posix/Makefile: Add rules to build and run bug-regex25 test.
454         * posix/bug-regex25.c: New test.
456 2006-06-02  Ryan S. Arnold  <rsa@us.ibm.com>
458         [BZ #2703]
459         * string/envz.c (envz_strip): Correct erroneously reversed src
460         and dest parameters to memmove() invocation.
462 2006-05-30  Jakub Jelinek  <jakub@redhat.com>
464         * nscd/nscd.h (prune_cache): Add fd argument to prototype.
465         * nscd/nscd.c (parse_opt): Read response from INVALIDATE request
466         to make sure the database has been already invalidated.
467         * nscd/cache.c (prune_cache): Add fd argument.  Write response to fd
468         after the cache has been invalidated.  Use pthread_mutex_lock rather
469         than pthread_mutex_trylock if fd != -1.
470         * nscd/connections.c (invalidate_cache): Add fd argument, write
471         response to fd if not calling prune_cache, pass fd to prune_cache.
472         (handle_request): Adjust invalidate_cache caller.
473         (nscd_run): Pass -1 as fd to prune_cache.
475 2006-05-30  Ulrich Drepper  <drepper@redhat.com>
477         * sysdeps/posix/getaddrinfo.c (gaiconf_init): Initialize bits in
478         the correct place.
480 2006-05-29  Ulrich Drepper  <drepper@redhat.com>
482         * nscd/nscd.h (struct database_dyn): Add prunelock field.
483         * nscd/cache.c (prune_cache): Take prunelock before starting the
484         work.  Just return in case it is already taken.
485         * nscd/connections.c (dbs): Initialize .prunelock.
487 2006-05-25  Ulrich Drepper  <drepper@redhat.com>
489         * nis/nis_removemember.c (nis_removemember): Avoid unnecessary
490         copying.  No need to allocate new array for group members.  Just
491         move the pointers and update the size.
493         * nis/nis_addmember.c (nis_addmember): Avoid unnecessary copying.
494         Avoid memory leak in case realloc fails.  Simplification for
495         better code generation.
497         Avoid deprecation warning because of libc_hidden_proto for
498         inet6_option_alloc.
499         * inet/inet6_option.c (option_alloc): Renamed from
500         inet6_option_alloc.  Made static.
501         (inet6_option_alloc): Now a simple wrapper around option_alloc.
502         (inet6_option_append): Call option_alloc.
503         * include/netinet/in.h: Remove libc_hidden_proto for
504         inet6_option_alloc.
506         * nis/nis_callback.c (__nis_create_callback): Always call xdr_free
507         for cleanup when cb!=NULL [Coverity CID 233].
509 2006-05-24  Ulrich Drepper  <drepper@redhat.com>
511         [BZ #2693]
512         * inet/Makefile (routines): Add inet6_opt and inet6_rth.
513         * inet/Versions (libc, GLIBC_2.5): Add inet6_opt_init,
514         inet6_opt_append, inet6_opt_finish, inet6_opt_set_val, inet6_opt_next,
515         inet6_opt_find, inet6_opt_get_val, inet6_rth_space, inet6_rth_init,
516         inet6_rth_add, inet6_rth_reverse, inet6_rth_segments,
517         and inet6_rth_getaddr.
518         * inet/netinet/ip6.h (struct ip6_rthdr0): Make ip6r0_addr a flexible
519         array.
520         * inet/netinet/in.h (struct ip6_mtuinfo): Define.
521         Mark inet6_option_* interfaces as deprecated.
522         Declare inet6_opt_init, inet6_opt_append, inet6_opt_finish,
523         inet6_opt_set_val, inet6_opt_next, inet6_opt_find, inet6_opt_get_val,
524         inet6_rth_space, inet6_rth_init, inet6_rth_add, inet6_rth_reverse,
525         inet6_rth_segments, and inet6_rth_getaddr.
526         * inet/inet6_opt.c: New file.
527         * inet/inet6_rth.c: New file.
529         * inet/netinet/icmp6.h: Pretty printing.
531         [BZ #2683]
532         * elf/dl-addr.c (_dl_addr): Don't match undefined references.
534 2006-05-23  Ulrich Drepper  <drepper@redhat.com>
536         * nis/nis_lookup.c (nis_lookup): Use __prepare_niscall instead of
537         doing it all here.  When server does not know the answer do not
538         fail immediate, try parent first.
540         * nis/nis_domain_of_r.c (nis_domain_of_r): Add missing buffer
541         overflow test.
543 2006-05-20  Ulrich Drepper  <drepper@redhat.com>
545         * nis/nis_call.c (__prepare_niscall): New function.  Split out
546         from __do_niscall.
547         * nis/nis_table.c (__create_ib_request): Renamed from create_ib_request
548         and exported.
549         (__follow_path): New function.  Split out from nis_list.
550         * nis/nis_xdr.h: Add libnsl_hidden_proto for _xdr_ib_request and
551         _xdr_nis_result.
552         * nis/nis_xdr.c: Add libnsl_hidden_def for _xdr_ib_request and
553         _xdr_nis_result.
554         * nis/libnsl.h: Declare __prepare_niscall, __create_ib_request,
555         and __follow_path.
556         * nis/Versions: Export __prepare_niscall, __create_ib_request,
557         __follow_path, __do_niscall3, _xdr_ib_request, and _xdr_nis_result
558         from libnsl for version GLIBC_PRIVATE.
559         * nis/nisplus-parser.h: Remove _nss_nisplus_parse_pwent_chk.
560         Remove entry parameter from _nss_nisplus_parse_pwent and
561         _nss_nisplus_parse_grent.
562         * nis/nss_nisplus/nisplus-parser.c: Likewise.
563         * nis/nss_nisplus/nisplus-pwd.c: Remove support for SETENT_BATCH_READ
564         again.  Rewrite getpwent handling to not use nis_first_entry and
565         nis_next_entry.  Roll out own niscall handling.
566         * nis/nss_nisplus/nisplus-grp.c: Likewise.
568         * sunrpc/xdr_rec.c: Fix typo in comment.
570 2006-05-19  Ulrich Drepper  <drepper@redhat.com>
572         * nis/nis_call.c (__do_niscall3): Avoid code duplication in error
573         handling.
575         * nis/nis_callback.c (internal_nis_do_callback): Don't use malloc
576         to allocate memory for my_pollfd.  Better initialization of
577         cb_is_running.  Use TEMP_FAILURE_RETRY.
579         * malloc/memusage.sh (memusageso): Add quotes.
580         (memusagestat): Likewise.
581         * debug/xtrace.sh (pcprofileso): Likewise.
582         (pcprofiledump): Likewise.
583         * debug/Makefile ($(objpfx)xtrace): Use $LIB in SLIBDIR
584         replacement.
585         * malloc/Makefile ($(objpfx)memusage): Likewise.
587         * nis/nis_callback.c (__nis_create_callback): Calls to
588         svcudp_bufcreate and svctcp_create can fail.  Free ->xprt if
589         asprintf call fails.
591         * sysdeps/unix/sysv/linux/ifaddrs.c (__netlink_sendreq): Make sure
592         no uninitialized memory is passed to sendto.
594 2006-05-18  Ulrich Drepper  <drepper@redhat.com>
596         * nis/nis_callback.c (__nis_create_callback): Use asprinf instead
597         of snprintf+strdup.  Handle OOM.
598         * nis/nis_callback.c (__nis_create_callback): Allocate cb and
599         cb->serv together.  Remove now obsolete free calls.
600         (__nis_destroy_callback): Remove now obsolete free call.
602 2006-05-18  David Woodhouse  <dwmw2@redhat.com>
604         * sysdeps/posix/getaddrinfo.c: Add unique labels to the default
605         RFC3484 precedence table for fec0::/10 and fc00::/7 (site-local
606         and ULA respectively). Set precedence for IPv4 address to 10 as
607         defined in RFC3484 for preferring IPv6.
608         * posix/gai.conf: Update to match the new default tables.
610 2006-05-18  Jakub Jelinek  <jakub@redhat.com>
612         * nis/nss_compat/compat-pwd.c (internal_setpwent): If nss_set*ent
613         returned NSS_STATUS_UNAVAIL, still return NSS_STATUS_SUCCESS.
614         * nis/nss_compat/compat-spwd.c (internal_setspent): Likewise.
615         * nis/nss_compat/compat-grp.c (internal_setgrent): Likewise.
617         * nis/nss_compat/compat-initgroups.c (nss_setgrent, nss_endgrent):
618         Removed.
619         (init_nss_interface): Remove initialization of these variables.
621 2006-05-18  Ulrich Drepper  <drepper@redhat.com>
623         * nis/nis_call.c (rec_dirsearch): Little optimization: pull
624         nis_free_directory forward to avoid duplication.
626 2006-05-17  Ulrich Drepper  <drepper@redhat.com>
628         * nis/nis_call.c (rec_dirsearch): Handle __nis_finddirectory and
629         rec_dirsearch returning NULL.
630         (first_shoot): Handle __nis_finddirectory returning NULL.
631         (__nisfind_server): Fix leak when rec_dirsearch returns NULL.
633         * sysdeps/unix/sysv/linux/sys/inotify.h: Define IN_CLOSE, IN_MOVE,
634         IN_ONLYDIR, IN_DONT_FOLLOW, and IN_MASK_ADD.
636 2006-05-17  Jakub Jelinek  <jakub@redhat.com>
638         * sunrpc/key_call.c (getkeyserv_handle): Call auth_destroy if
639         pid changed.
641 2006-05-15  Ulrich Drepper  <drepper@redhat.com>
643         * include/rpc/pmap_prot.h: Mark all functions as hidden.
645         * nscd/nscd_initgroups.c: Mark __gr_map_handle as hidden.
646         * nscd/nscd_getgr_r.c: Likewise.
648         * include/rpc/pmap_rmt.h: Mark all functions as hidden.
650         * nscd/nscd_getai.c (__hst_map_handle): Mark as hidden.
651         * nscd/nscd_gethst_r.c (__hst_map_handle): Likewise.
653         * stdlib/longlong.h (__clz_tab): Mark as hidden.
655         * iconv/gconv_int.h: Mark __gconv_lock as hidden.
657         * include/rpc/key_prot.h: Mark all _internal functions as hidden.
659         * include/rpc/auth.h: Mark xdr_des_block_internal and
660         xdr_opaque_auth_internal as hidden.
662         * sysdeps/unix/sysv/linux/getdents.c: Mark __have_no_getdents64 as
663         hidden.
665         * include/rpc/xdr.h: Mark all _internal functions as hidden.
667         * misc/getusershell.c (okshells): Don't use static initializers,
668         do it dynamically.
670         * stdlib/fmtmsg.c (keywords): Change type of len element to
671         uint32_t to not waste space on 64bit machines.
673         * locale/setlocale.c: Change _nl_category_names into a string.
674         Add new _nl_category_name_idxs.  Change all users.
675         * locale/localeinfo.h: Adjust declaration of _nl_category_names.
676         Declare _nl_category_name_idxs.
677         * locale/findlocale.c: Adjust for _nl_category_names change.
678         * locale/loadlocale.c: Likewise.
679         * locale/newlocale.c: Likewise.
680         * intl/dcigettext.c: Likewise.
682         * iconv/gconv_conf.c (add_alias): Move actual alias handling to...
683         (add_alias2): ...here.  New function.
684         (__gconv_read_conf): Simplify builtin alias handling.
685         (builtin_aliases): Convert to string to avoid relocations.
686         * iconv/gconv_builtin.h: Add comment about correct formatting.
688 2006-05-15  Jakub Jelinek  <jakub@redhat.com>
690         * resolv/res_debug.c (loc_ntoa): Make error const.
692 2006-05-14  Andreas Schwab  <schwab@suse.de>
694         * math/complex.h [__LDBL_COMPAT]: Use __REDIRECT_NTH.
696 2006-05-12  Jakub Jelinek  <jakub@redhat.com>
698         * sysdeps/unix/sysv/linux/sched_getaffinity.c: Include sys/param.h.
699         (__sched_getaffinity_new): Don't crash if cpusetsize is smaller than
700         sizeof (cpu_set_t).
702 2006-05-11  Ulrich Drepper  <drepper@redhat.com>
704         * resolv/res_debug.c (loc_ntoa): Define error as array, not pointer.
706         * include/arpa/nameser.h: Declare _ns_flagdata as hidden.
708         * nis/yp_xdr.c: Add libnsl_hidden_def for xdr_ypresp_master.
709         * include/rpcsvc/yp.h: Add libnsl_hidden_proto for xdr_ypresp_master.
711         * nis/yp_xdr.c: Add libnsl_hidden_def for xdr_ypbind_resp.
712         * include/rpcsvc/yp.h: Add libnsl_hidden_proto for xdr_ypbind_resp.
714         * nis/nis_xdr.c: Add libnsl_hidden_def for xdr_cback_data.
715         * include/rpcsvc/nis_callback.h: Add libnsl_hidden_proto for
716         xdr_cback_data.
718         * nis/ypupdate_xdr.c: Add libnsl_hidden_def for xdr_ypupdate_args.
719         * include/rpcsvc/ypupd.h: Add libnsl_hidden_proto for
720         xdr_ypupdate_args.
722         * nis/yp_xdr.c: Add libnsl_hidden_def for xdr_ypresp_order.
723         * include/rpcsvc/yp.h: Add libnsl_hidden_proto for xdr_ypresp_order.
725         * nis/yp_xdr.c: Add libnsl_hidden_def for xdr_ypresp_maplist.
726         * include/rpcsvc/yp.h: Add libnsl_hidden_proto for xdr_ypresp_maplist.
728         * nis/nis_xdr.c: Add libnsl_hidden_def for xdr_obj_p.
729         * include/rpcsvc/nis_callback.h: New file.
731         * nis/yp_xdr.c: Add libnsl_hidden_def for xdr_ypresp_val.
732         * include/rpcsvc/yp.h: Add libnsl_hidden_proto for xdr_ypresp_val.
734         * nis/yp_xdr.c: Add libnsl_hidden_def for xdr_ypreq_nokey.
735         * include/rpcsvc/yp.h: Add libnsl_hidden_proto for xdr_ypreq_nokey.
737         * nis/yp_xdr.c: Add libnsl_hidden_def for xdr_ypmaplist.
738         * include/rpcsvc/yp.h: Add libnsl_hidden_proto for xdr_ypmaplist.
740         * nis/yp_xdr.c: Add libnsl_hidden_def for xdr_ypreq_nokey.
741         * include/rpcsvc/yp.h: Add libnsl_hidden_proto for xdr_ypreq_nokey.
743         * nis/ypupdate_xdr.c: Add libnsl_hidden_def for xdr_ypdelete_args.
744         * include/rpcsvc/ypupd.h: Add libnsl_hidden_proto for
745         xdr_ypdelete_args.
747         * nis/nis_xdr.h: Mark all functions as hidden.  Remove
748         __BEGIN_DECLS and __END_DECLS, the header is not installed.
750         * nis/nis_error.c: Remove table of strings.  Use position
751         independent mechanism.
752         * nis/nis_error.h: New file.
754 2006-05-11  Jakub Jelinek  <jakub@redhat.com>
756         * locale/programs/ld-time.c (time_finish): If wide era name or
757         format aren't provided, set both wname and wformat to L"".
759 2006-05-10  Ulrich Drepper  <drepper@redhat.com>
761         * sysdeps/unix/sysv/linux/tcgetattr.c (__tcgetattr): Only store
762         results if the call was succesful.
764         * nis/nss-nis.h: Mark __yperr2nss_tab and __yperr2nss_count as hidden.
766         * nis/nss-nisplus.h: Mark __niserr2nss_tab and __niserr2nss_count
767         as hidden.
769 2006-05-10  Jakub Jelinek  <jakub@redhat.com>
771         * misc/sys/queue.h: Remove uses of all QUEUEDEBUG_* macros.
773 2006-05-10  Ulrich Drepper  <drepper@redhat.com>
775         * posix/wordexp.c (parse_glob): No need to check ifs for NULL, the
776         caller makes sure this is not the case.
777         (wordexp): Simplify ifs_white creation.  [Coverity CID 231]
779 2006-05-09  Ulrich Drepper  <drepper@redhat.com>
781         * posix/wordexp.c: Remove numerous NULL pointer tests before FREE
782         calls.
784         * io/ftw.c (open_dir_stream): Return right away if REALLOC fails.
785         [Coverity CID 229, 230]
787         * argp/argp-help.c (hol_entry_help): Handle STATE==NULL in ARG and
788         DGETTEXT calls.
789         (hol_help): Likewise.  [Coverity CID 226, 227]
791         * string/argz-replace.c (__argz_replace): Unconditionally call
792         free on SRC.  [Coverity CID 225]
794         * nis/nis_creategroup.c (nis_creategroup): No need to duplicate
795         the return value of __nis_default_owner and __nis_default_group,
796         it has been especially allocated.  [Coverity CID 224]
798         * nis/nis_defaults.c (searchXYX): New functions.  Used by both
799         searchgroup and searchowner.  Significantly simplified.
800         (__nis_default_owner): Remove duplication.  Do not locally copy the
801         string before duplicating it.
802         (__nis_default_group): Likewise.
804         * nis/nis_lookup.c (nis_lookup): After calling nis_free_directory,
805         we must clear the variable before calling __nisfind_server.
807         * nis/nis_lookup.c (nis_lookup): Always free memory allocated with
808         nis_getnames.  [Coverity CID 223]
810         * locale/programs/locfile.c (locfile_read): Use alloca instead of
811         xmalloc to allocate local repertoire name.  [Coverity CID 222]
813         * iconv/iconv_charmap.c (use_to_charmap): No need to dynamically
814         allocate memory for the input to add_bytes.  [Coverity CID 221]
816         * posix/wordexp.c (w_addword): Free word if realloc fails and it
817         was allocated here.  [Coverity CID 219, 220]
819         * posix/getconf.c (print_all): Free confstr data after printing.
820         [Coverity CID 218]
822         * sysdeps/posix/getaddrinfo.c (gaih_inet): Free canon string if
823         list allocation fails.  [Coverity CID 215]
825         * nss/nsswitch.c (__nss_configure_lookup): Fix loop end condition.
826         [Coverity CID 213]
828         * argp/argp-help.c (hol_entry_cmp): Don't call canon_doc_option if
829         string is NULL.  [Coverity CID 212]
830         * argp/Makefile: Add rules to build and run bug-argp1.
831         * argp/bug-argp1.c: New file.
833         * io/ftw.c (ftw_dir): Use __rawmemchr instead of strchr to find
834         end of string.
835         * stdlib/canonicalize.c (__realpath): Likewise.
837         * locale/programs/ld-time.c (time_finish): Don't dereference NULL
838         pointer.  [Coverity CID 206]
840         * elf/dl-dst.h (DL_DST_REQUIRED): Be prepared for missing link map
841         in statically linked code.
842         * elf/dl-load.c (_dl_dst_substitute): When replacing ORIGIN in
843         statically built code, be prepared to have no link map.
844         [Coverity CID 205]
846         * argp/argp-help.c (fill_in_uparams): Handle STATE==NULL in
847         dgettext calls. [Coverity CID 204]
849         * argp/argp-help.c (struct uparams): Remove valid member.  Change
850         the one user.
851         (uparam_names): Reduce size.  Avoid relative relocations.
852         Moved to read-only segment.
853         (fill_in_uparams): Update for new layout.
855         * sysdeps/unix/sysv/linux/ifaddrs.c (getifaddrs): Parameter can be
856         assumed to always be != NULL. [Coverity CID 202]
858         * argp/argp-help.c (hol_entry_help): Remove some dead code
859         [Coverity CID 200].
861         * nis/nss_nis/nis-service.c (_nss_nis_getservbyport_r): Optimize
862         away a few more unconditional yperr2nss calls.
863         (_nss_nis_getservbyname_r): Likewise.
865 2006-05-06  Ulrich Drepper  <drepper@redhat.com>
867         * sysdeps/generic/ldsodefs.h: Remove support for non-core
868         architectures.
870         * sysdeps/unix/sysv/linux/check_pf.c (make_request): Make sure
871         that unused memory passed to sendto is nevertheless initialized.
873         [BZ #2499]
874         * resolv/nss_dns/dns-canon.c (_nss_dns_getcanonname_r): Avoid
875         possibly unaligned memory accesses.
877         * include/arpa/nameser.h: Also optimize NS_PUT16 and NS_PUT32.
878         * resolv/res_mkquery.c: Use NS_PUT16 and NS_PUT32 instead of __putshort
879         and __putlong respectively.  Correct buffer overflow check for
880         NS_NOTIFY_OP.
882         * resolv/res_send.c (send_vc): Use ns_put16 instead of putshort.
884         * resolv/res_send.c (res_queriesmatch): Fix typo in comment.
885         (send_dg): Rewrite error handling to be more compact and avoid
886         double recomputation of timeouts.  Pass MSG_NOSIGNAL to send.
888         * include/arpa/nameser.h: Add optimizations for NS_GET16 and NS_GET32.
890         * resolv/res_send.c (res_nameinquery): Use NS_GET16 directly
891         instead of ns_get16.
892         (res_queriesmatch): Likewise.  Minor optimization.
894         [BZ #2499]
895         * resolv/res_query.c (__libc_res_nquery): If answerp != NULL,
896         __libc_res_nsend might reallocate the buffer for the answer.  In
897         this case we have to reload the HP pointer.
899 2006-05-05  Ulrich Drepper  <drepper@redhat.com>
901         * stdio-common/vfscanf.c (memory_error): Remove definition.  Add
902         some branch prediction hints.
904         * sysdeps/unix/sysv/linux/sparc/bits/fcntl.h: Define SPLICE_F_*.
905         * sysdeps/unix/sysv/linux/ia64/bits/fcntl.h: Likewise.
906         * sysdeps/unix/sysv/linux/sh/bits/fcntl.h: Likewise.
907         * sysdeps/unix/sysv/linux/i386/bits/fcntl.h: Likewise.
908         * sysdeps/unix/sysv/linux/s390/bits/fcntl.h: Likewise.
909         * sysdeps/unix/sysv/linux/x86_64/bits/fcntl.h: Likewise.
910         * sysdeps/unix/sysv/linux/alpha/bits/fcntl.h: Likewise.
911         * sysdeps/unix/sysv/linux/powerpc/bits/fcntl.h: Likewise.
913 2006-05-05  Martin Schwidefsky  <schwidefsky@de.ibm.com>
915         * sysdeps/s390/s390-32/elf/start.S: Replace pc relative relocation
916         by a GOT relocation to make Scrt1.o position independent.
917         * sysdeps/s390/s390-64/elf/start.S: Likewise.
919         * sysdeps/unix/sysv/linux/s390/s390-32/syscall.S: Add support for
920         six system call parameters.
921         * sysdeps/unix/sysv/linux/s390/s390-64/syscall.S: Likewise.
923 2006-05-05  Ulrich Drepper  <drepper@redhat.com>
925         * sunrpc/svcauth_des.c (cache_init): Use calloc instead of
926         malloc&bzero.
928         * sunrpc/svc_udp.c (BZERO): Remove definition.
929         (CALLOC): Define.
930         (svc_enablecache): Use CALLOC instead of ALLOC&BZERO.
932         * sunrpc/des_impl.c: Remove ALT_ECB support.  We never used it.
933         (des_SPtrans): Use uint32_t type.
934         (des_skb): Likewise.
936         * sunrpc/xdr_ref.c (xdr_reference): Use calloc instead of malloc&bzero.
938 2006-05-05  Jakub Jelinek  <jakub@redhat.com>
940         [BZ #2509]
941         * stdio-common/tst-printf.sh: Adjust for tst-printf.c change even
942         on 32-bit arches.
944 2006-05-05  Ulrich Drepper  <drepper@redhat.com>
946         * locale/programs/ld-address.c (address_finish): Fix one more
947         place where the iso639 array might be accessed beyond the limits.
949 2006-05-04  Ulrich Drepper  <drepper@redhat.com>
951         * nis/nis_table.c (nis_list): Avoid clearing res twice before
952         filling it for the first time.
954         * nis/nis_table.c (get_tablepath): Renamed from __get_tablepath.
955         Adjust all callers.
956         Free res object content before returning.
958         * sunrpc/xdr_array.c (xdr_array): Use calloc instead of malloc&bzero.
960         * sunrpc/key_call.c (__rpc_thread_key_cleanup): Also free
961         client->cl_auth.
963         * sunrpc/rpc_thread.c (__rpc_thread_destroy): Don't skip entire
964         cleanup for initial thread, just the free call on TVP.
966         * nscd/gai.c (__getline): Define.
969 See ChangeLog.16 for earlier changes.