summaryrefslogtreecommitdiffstats
path: root/utils/ldd.c
diff options
context:
space:
mode:
author"Steven J. Hill" <sjhill@realitydiluted.com>2007-01-20 20:09:04 +0000
committer"Steven J. Hill" <sjhill@realitydiluted.com>2007-01-20 20:09:04 +0000
commit4fa703c12bc4e5f1f61dc970350fd184b97187d3 (patch)
treea6f9d28e9c6e048ca58eb072232e1c9ec5fff389 /utils/ldd.c
parent60258bd2670e1aac497702bef2427318f3921641 (diff)
downloaduClibc-alpine-4fa703c12bc4e5f1f61dc970350fd184b97187d3.tar.bz2
uClibc-alpine-4fa703c12bc4e5f1f61dc970350fd184b97187d3.tar.xz
Merge from trunk.
Diffstat (limited to 'utils/ldd.c')
-rw-r--r--utils/ldd.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/utils/ldd.c b/utils/ldd.c
index b454779e1..65aeb31fb 100644
--- a/utils/ldd.c
+++ b/utils/ldd.c
@@ -27,8 +27,8 @@
#include "bswap.h"
#include "link.h"
-#include "elf.h"
#include "dl-defs.h"
+/* makefile will include elf.h for us */
#ifdef DMALLOC
#include <dmalloc.h>
@@ -287,7 +287,7 @@ int map_cache(void)
if (stat(LDSO_CACHE, &st)
|| (fd = open(LDSO_CACHE, O_RDONLY, 0)) < 0) {
- dprintf(2, "ldd: can't open cache '%s'\n", LDSO_CACHE);
+ fprintf(stderr, "ldd: can't open cache '%s'\n", LDSO_CACHE);
cache_addr = (caddr_t) - 1; /* so we won't try again */
return -1;
}
@@ -296,7 +296,7 @@ int map_cache(void)
cache_addr = (caddr_t) mmap(0, cache_size, PROT_READ, MAP_SHARED, fd, 0);
close(fd);
if (cache_addr == MAP_FAILED) {
- dprintf(2, "ldd: can't map cache '%s'\n", LDSO_CACHE);
+ fprintf(stderr, "ldd: can't map cache '%s'\n", LDSO_CACHE);
return -1;
}
@@ -309,7 +309,7 @@ int map_cache(void)
(sizeof(header_t) + header->nlibs * sizeof(libentry_t))
|| cache_addr[cache_size - 1] != '\0')
{
- dprintf(2, "ldd: cache '%s' is corrupt\n", LDSO_CACHE);
+ fprintf(stderr, "ldd: cache '%s' is corrupt\n", LDSO_CACHE);
goto fail;
}
@@ -321,7 +321,7 @@ int map_cache(void)
if (libent[i].sooffset >= strtabsize ||
libent[i].liboffset >= strtabsize)
{
- dprintf(2, "ldd: cache '%s' is corrupt\n", LDSO_CACHE);
+ fprintf(stderr, "ldd: cache '%s' is corrupt\n", LDSO_CACHE);
goto fail;
}
}