From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 48121 invoked by alias); 7 Jun 2018 18:06:25 -0000 Mailing-List: contact elfutils-devel-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Post: List-Help: List-Subscribe: Sender: elfutils-devel-owner@sourceware.org Received: (qmail 47750 invoked by uid 89); 7 Jun 2018 18:06:22 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Checked: by ClamAV 0.99.4 on sourceware.org X-Virus-Found: No X-Spam-SWARE-Status: No, score=-26.9 required=5.0 tests=BAYES_00,GIT_PATCH_0,GIT_PATCH_1,GIT_PATCH_2,GIT_PATCH_3,RCVD_IN_DNSWL_NONE,SPF_PASS autolearn=ham version=3.3.2 spammy= X-Spam-Status: No, score=-26.9 required=5.0 tests=BAYES_00,GIT_PATCH_0,GIT_PATCH_1,GIT_PATCH_2,GIT_PATCH_3,RCVD_IN_DNSWL_NONE,SPF_PASS autolearn=ham version=3.3.2 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on sourceware.org X-Spam-Level: X-HELO: gnu.wildebeest.org Received: from wildebeest.demon.nl (HELO gnu.wildebeest.org) (212.238.236.112) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Thu, 07 Jun 2018 18:06:20 +0000 Received: from librem.wildebeest.org (deer0x15.wildebeest.org [172.31.17.151]) (using TLSv1.2 with cipher ADH-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by gnu.wildebeest.org (Postfix) with ESMTPSA id 394DC307C548; Thu, 7 Jun 2018 20:06:17 +0200 (CEST) Received: by librem.wildebeest.org (Postfix, from userid 1000) id B6405142C7E; Thu, 7 Jun 2018 20:06:12 +0200 (CEST) From: Mark Wielaard To: elfutils-devel@sourceware.org Cc: Mark Wielaard Subject: [COMMITTED] readelf: Lookup "no" translation for no_str, not "yes". Date: Thu, 07 Jun 2018 18:06:00 -0000 Message-Id: <20180607180610.25456-1-mark@klomp.org> X-Mailer: git-send-email 2.17.0 X-Spam-Flag: NO X-IsSubscribed: yes X-SW-Source: 2018-q2/txt/msg00166.txt.bz2 On irc Tom pointed out that no was yes... oops. Committed as obvious. Also use yes_str and no_str in print_debug_abbrev_section and print_form_data. Signed-off-by: Mark Wielaard --- src/ChangeLog | 6 ++++++ src/readelf.c | 6 +++--- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/src/ChangeLog b/src/ChangeLog index 37e24714..d6fc919a 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,9 @@ +2018-06-07 Mark Wielaard + + * readelf.c (main): Lookup "no" for no_str. + (print_debug_abbrev_section): Use yes_str and no_str. + (print_form_data): Likewise. + 2018-06-04 Mark Wielaard * readelf (format_result): New static char pointer. diff --git a/src/readelf.c b/src/readelf.c index 8f37f17b..6ac45111 100644 --- a/src/readelf.c +++ b/src/readelf.c @@ -327,7 +327,7 @@ main (int argc, char *argv[]) /* Look up once. */ yes_str = gettext ("yes"); - no_str = gettext ("yes"); + no_str = gettext ("no"); /* Parse and process arguments. */ int remaining; @@ -5062,7 +5062,7 @@ print_debug_abbrev_section (Dwfl_Module *dwflmod __attribute__ ((unused)), printf (gettext (" [%5u] offset: %" PRId64 ", children: %s, tag: %s\n"), code, (int64_t) offset, - has_children ? gettext ("yes") : gettext ("no"), + has_children ? yes_str : no_str, dwarf_tag_name (tag)); size_t cnt = 0; @@ -7955,7 +7955,7 @@ print_form_data (Dwarf *dbg, int form, const unsigned char *readp, if (readendp - readp < 1) goto invalid_data; val = *readp++; - printf ("%s", val != 0 ? gettext ("yes") : gettext ("no")); + printf ("%s", val != 0 ? yes_str : no_str); break; case DW_FORM_string: -- 2.17.0