aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2002-03-15 03:09:42 +0000
committerUlrich Drepper <drepper@redhat.com>2002-03-15 03:09:42 +0000
commit36461455978549862873b9fa1117de21984dceac (patch)
tree5572c7591ebf03c0413e2c7f8204383140d00db7
parent212baf8d3a67d592368813ab0df6d22f3a51f936 (diff)
downloadglibc-36461455978549862873b9fa1117de21984dceac.tar
glibc-36461455978549862873b9fa1117de21984dceac.tar.gz
glibc-36461455978549862873b9fa1117de21984dceac.tar.bz2
glibc-36461455978549862873b9fa1117de21984dceac.zip
(malloc): Declare _end as hidden. (__errno_location): New function. Declare errno as hidden.
-rw-r--r--elf/dl-minimal.c19
1 files changed, 16 insertions, 3 deletions
diff --git a/elf/dl-minimal.c b/elf/dl-minimal.c
index 9b9d34b07d..0f284d0a80 100644
--- a/elf/dl-minimal.c
+++ b/elf/dl-minimal.c
@@ -37,8 +37,10 @@ static void *alloc_ptr, *alloc_end, *alloc_last_block;
/* Declarations of global functions. */
extern void weak_function free (void *ptr);
extern void * weak_function realloc (void *ptr, size_t n);
-extern unsigned long int weak_function __strtoul_internal
-(const char *nptr, char **endptr, int base, int group);
+extern unsigned long int weak_function __strtoul_internal (const char *nptr,
+ char **endptr,
+ int base,
+ int group);
extern unsigned long int weak_function strtoul (const char *nptr,
char **endptr, int base);
@@ -59,7 +61,7 @@ malloc (size_t n)
if (alloc_end == 0)
{
/* Consume any unused space in the last page of our data segment. */
- extern int _end;
+ extern int _end attribute_hidden;
alloc_ptr = &_end;
alloc_end = (void *) 0 + (((alloc_ptr - (void *) 0)
+ GL(dl_pagesize) - 1)
@@ -350,3 +352,14 @@ strong_alias (__strsep, __strsep_g)
up to 36. We don't need this here. */
const char INTUSE(_itoa_lower_digits)[16] attribute_hidden
= "0123456789abcdef";
+
+
+#undef errno
+/* The 'errno' in ld.so is not exported. */
+extern int errno attribute_hidden;
+
+int *
+__errno_location (void)
+{
+ return &errno;
+}