+2006-10-13 Ulrich Drepper <drepper@redhat.com>
+
+ * elf/dl-minimal.c (realloc): Optimize last patch.
+
2006-10-12 Richard Sandiford <richard@codesourcery.com>
[BZ #3352]
* elf/dl-minimal.c (realloc): Let malloc() return a new pointer,
and use memcpy() if it does.
-
+
2006-11-12 Andreas Jaeger <aj@suse.de>
[BZ #2510]
/* Minimal replacements for basic facilities used in the dynamic linker.
- Copyright (C) 1995-1998,2000-2002,2004,2005 Free Software Foundation, Inc.
+ Copyright (C) 1995-1998,2000-2002,2004,2005,2006
+ Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
size_t old_size = alloc_ptr - alloc_last_block;
alloc_ptr = alloc_last_block;
void *new = malloc (n);
- if (new != ptr)
- memcpy (new, ptr, old_size);
- return new;
+ return new != ptr ? memcpy (new, ptr, old_size) : new;
}
\f
/* Avoid signal frobnication in setjmp/longjmp. Keeps things smaller. */