From patchwork Thu Feb 26 10:54:35 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jan Kratochvil X-Patchwork-Id: 5304 Received: (qmail 130501 invoked by alias); 26 Feb 2015 10:54:45 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Delivered-To: mailing list gdb-patches@sourceware.org Received: (qmail 130486 invoked by uid 89); 26 Feb 2015 10:54:44 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-3.9 required=5.0 tests=AWL, BAYES_00, SPF_HELO_PASS, T_RP_MATCHES_RCVD autolearn=ham version=3.3.2 X-HELO: mx1.redhat.com Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES256-GCM-SHA384 encrypted) ESMTPS; Thu, 26 Feb 2015 10:54:43 +0000 Received: from int-mx11.intmail.prod.int.phx2.redhat.com (int-mx11.intmail.prod.int.phx2.redhat.com [10.5.11.24]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id t1QAseik028555 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=FAIL); Thu, 26 Feb 2015 05:54:40 -0500 Received: from host1.jankratochvil.net ([10.40.204.17]) by int-mx11.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id t1QAsZ9X030436 (version=TLSv1/SSLv3 cipher=AES256-SHA bits=256 verify=NO); Thu, 26 Feb 2015 05:54:38 -0500 Date: Thu, 26 Feb 2015 11:54:35 +0100 From: Jan Kratochvil To: Joel Brobecker Cc: Phil Muldoon , gdb-patches@sourceware.org Subject: Re: [patchv2] compile: Fix GNU-IFUNC funcs called from injected code Message-ID: <20150226105435.GA2828@host1.jankratochvil.net> References: <20150224190720.GA32497@host1.jankratochvil.net> <20150224200237.GA1746@host1.jankratochvil.net> <54ED85CC.7030506@redhat.com> <20150225172944.GA28033@host1.jankratochvil.net> <20150226081800.GA31815@adacore.com> <20150226083000.GA30858@host1.jankratochvil.net> <20150226093403.GC31815@adacore.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20150226093403.GC31815@adacore.com> User-Agent: Mutt/1.5.23 (2014-03-12) X-IsSubscribed: yes On Thu, 26 Feb 2015 10:34:03 +0100, Joel Brobecker wrote: > As one of the authors of this patch, can you fix those, please? > (obvious fix, master and gdb-7.9-branch - remember that we need > a PR for fixes pushed to the branch) Done, also in the 7.9 branch. Used your PR, only now I read I should have probably used a new one. Jan --- gdb/compile/compile-c-support.c | 2 +- gdb/compile/compile-object-load.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/gdb/compile/compile-c-support.c b/gdb/compile/compile-c-support.c index 8f1f45d..1711cda 100644 --- a/gdb/compile/compile-c-support.c +++ b/gdb/compile/compile-c-support.c @@ -351,7 +351,7 @@ c_compute_program (struct compile_instance *inst, " __gdb_intptr;\n", buf); - // Iterate all log2 sizes in bytes supported by c_get_mode_for_size. + /* Iterate all log2 sizes in bytes supported by c_get_mode_for_size. */ for (i = 0; i < 4; ++i) { const char *mode = c_get_mode_for_size (1 << i); diff --git a/gdb/compile/compile-object-load.c b/gdb/compile/compile-object-load.c index 5903f18..e187970 100644 --- a/gdb/compile/compile-object-load.c +++ b/gdb/compile/compile-object-load.c @@ -67,7 +67,7 @@ setup_sections (bfd *abfd, asection *sect, void *data_voidp) if ((bfd_get_section_flags (abfd, sect) & SEC_ALLOC) == 0) return; - // Make the memory always readable. + /* Make the memory always readable. */ prot = GDB_MMAP_PROT_READ; if ((bfd_get_section_flags (abfd, sect) & SEC_READONLY) == 0) prot |= GDB_MMAP_PROT_WRITE;