From 1c0e33852ebc6380b0d049bc3ec58d45a09dcd15 Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Wed, 31 Jan 2007 12:13:13 +0000 Subject: * Print error messages on stderr. --- src/patchelf.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/patchelf.cc b/src/patchelf.cc index 03ff227..bec7406 100644 --- a/src/patchelf.cc +++ b/src/patchelf.cc @@ -57,7 +57,7 @@ static void debug(const char * format, ...) static void error(string msg) { - if (errno) perror(msg.c_str()); else printf("%s\n", msg.c_str()); + if (errno) perror(msg.c_str()); else fprintf(stderr, "%s\n", msg.c_str()); exit(1); } @@ -267,7 +267,7 @@ static void rewriteSections() for (unsigned int i = 1; i < hdr->e_shnum; ++i) { string sectionName = getSectionName(shdrs[i]); if (replacedSections.find(sectionName) != replacedSections.end()) { - printf("using replaced section `%s'\n", sectionName.c_str()); + fprintf(stderr, "using replaced section `%s'\n", sectionName.c_str()); lastReplaced = i; } } -- cgit v0.12