From patchwork Fri Mar 20 16:56:39 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yao Qi X-Patchwork-Id: 5732 Received: (qmail 33515 invoked by alias); 20 Mar 2015 16:57:01 -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 33459 invoked by uid 89); 20 Mar 2015 16:57:01 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=2.4 required=5.0 tests=AWL, BAYES_00, FREEMAIL_FROM, KAM_FROM_URIBL_PCCC, RCVD_IN_DNSWL_LOW, SPF_PASS autolearn=no version=3.3.2 X-HELO: mail-pa0-f42.google.com Received: from mail-pa0-f42.google.com (HELO mail-pa0-f42.google.com) (209.85.220.42) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES128-GCM-SHA256 encrypted) ESMTPS; Fri, 20 Mar 2015 16:57:00 +0000 Received: by pagj4 with SMTP id j4so23040298pag.2 for ; Fri, 20 Mar 2015 09:56:58 -0700 (PDT) X-Received: by 10.70.53.40 with SMTP id y8mr159933762pdo.61.1426870618399; Fri, 20 Mar 2015 09:56:58 -0700 (PDT) Received: from E107787-LIN.cambridge.arm.com (gcc1-power7.osuosl.org. [140.211.15.137]) by mx.google.com with ESMTPSA id i10sm8983383pdk.53.2015.03.20.09.56.57 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Fri, 20 Mar 2015 09:56:57 -0700 (PDT) From: Yao Qi To: gdb-patches@sourceware.org Subject: [PATCH 8/9] constify set_breakpoint_condition Date: Fri, 20 Mar 2015 16:56:39 +0000 Message-Id: <1426870600-17876-9-git-send-email-qiyaoltc@gmail.com> In-Reply-To: <1426870600-17876-1-git-send-email-qiyaoltc@gmail.com> References: <1426870600-17876-1-git-send-email-qiyaoltc@gmail.com> X-IsSubscribed: yes From: Pedro Alves gdb: 2015-03-20 Pedro Alves * breakpoint.c (set_breakpoint_condition): Make argument "exp" const. * breakpoint.h (set_breakpoint_condition): Update declaration. --- gdb/breakpoint.c | 2 +- gdb/breakpoint.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/gdb/breakpoint.c b/gdb/breakpoint.c index 0c000f2..13c8949 100644 --- a/gdb/breakpoint.c +++ b/gdb/breakpoint.c @@ -957,7 +957,7 @@ get_first_locp_gte_addr (CORE_ADDR address) } void -set_breakpoint_condition (struct breakpoint *b, char *exp, +set_breakpoint_condition (struct breakpoint *b, const char *exp, int from_tty) { xfree (b->cond_string); diff --git a/gdb/breakpoint.h b/gdb/breakpoint.h index b85939a..562a6b6 100644 --- a/gdb/breakpoint.h +++ b/gdb/breakpoint.h @@ -1525,7 +1525,7 @@ extern int breakpoints_should_be_inserted_now (void); extern void breakpoint_retire_moribund (void); /* Set break condition of breakpoint B to EXP. */ -extern void set_breakpoint_condition (struct breakpoint *b, char *exp, +extern void set_breakpoint_condition (struct breakpoint *b, const char *exp, int from_tty); /* Checks if we are catching syscalls or not.