mirror of
https://sourceware.org/git/glibc.git
synced 2025-07-30 22:43:12 +03:00
Remove __morecore and __default_morecore
Make the __morecore and __default_morecore symbols compat-only and remove their declarations from the API. Also, include morecore.c directly into malloc.c; this should ideally get merged into malloc in a future cleanup. Reviewed-by: Carlos O'Donell <carlos@redhat.com> Tested-by: Carlos O'Donell <carlos@redhat.com>
This commit is contained in:
@ -274,14 +274,6 @@ next_env_entry (char ***position)
|
||||
#endif
|
||||
|
||||
|
||||
#if defined(SHARED) || defined(USE_MTAG)
|
||||
static void *
|
||||
__failing_morecore (ptrdiff_t d)
|
||||
{
|
||||
return (void *) MORECORE_FAILURE;
|
||||
}
|
||||
#endif
|
||||
|
||||
#ifdef SHARED
|
||||
extern struct dl_open_hook *_dl_open_hook;
|
||||
libc_hidden_proto (_dl_open_hook);
|
||||
@ -310,7 +302,7 @@ ptmalloc_init (void)
|
||||
and that morecore does not support tagged regions, then
|
||||
disable it. */
|
||||
if (__MTAG_SBRK_UNTAGGED)
|
||||
__morecore = __failing_morecore;
|
||||
__always_fail_morecore = true;
|
||||
|
||||
mtag_enabled = true;
|
||||
mtag_mmap_flags = __MTAG_MMAP_FLAGS;
|
||||
@ -323,7 +315,7 @@ ptmalloc_init (void)
|
||||
generic sbrk implementation also enforces this, but it is not
|
||||
used on Hurd. */
|
||||
if (!__libc_initial)
|
||||
__morecore = __failing_morecore;
|
||||
__always_fail_morecore = true;
|
||||
#endif
|
||||
|
||||
thread_arena = &main_arena;
|
||||
|
Reference in New Issue
Block a user