From patchwork Tue Jul 22 18:55:09 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tom Tromey X-Patchwork-Id: 2135 Received: (qmail 25223 invoked by alias); 22 Jul 2014 18:55:29 -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 25144 invoked by uid 89); 22 Jul 2014 18:55:29 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.8 required=5.0 tests=AWL, BAYES_00, RP_MATCHES_RCVD, SPF_HELO_PASS, SPF_PASS 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; Tue, 22 Jul 2014 18:55:28 +0000 Received: from int-mx14.intmail.prod.int.phx2.redhat.com (int-mx14.intmail.prod.int.phx2.redhat.com [10.5.11.27]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id s6MItQQK017351 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK) for ; Tue, 22 Jul 2014 14:55:26 -0400 Received: from barimba.redhat.com (ovpn-113-154.phx2.redhat.com [10.3.113.154]) by int-mx14.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id s6MItMWS000387; Tue, 22 Jul 2014 14:55:25 -0400 From: Tom Tromey To: gdb-patches@sourceware.org Cc: Tom Tromey Subject: [PATCH 03/13] constify inf_child_open_target Date: Tue, 22 Jul 2014 12:55:09 -0600 Message-Id: <1406055319-26380-4-git-send-email-tromey@redhat.com> In-Reply-To: <1406055319-26380-1-git-send-email-tromey@redhat.com> References: <1406055319-26380-1-git-send-email-tromey@redhat.com> This constifies an argument to inf_child_open_target. 2014-07-22 Tom Tromey * inf-child.c (inf_child_open_target): Make "arg" const. * inf-child.h (inf_child_open_target): Update. --- gdb/ChangeLog | 5 +++++ gdb/inf-child.c | 3 ++- gdb/inf-child.h | 2 +- 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/gdb/inf-child.c b/gdb/inf-child.c index 897e635..883ed77 100644 --- a/gdb/inf-child.c +++ b/gdb/inf-child.c @@ -122,7 +122,8 @@ static int inf_child_explicitly_opened; /* See inf-child.h. */ void -inf_child_open_target (struct target_ops *target, char *arg, int from_tty) +inf_child_open_target (struct target_ops *target, const char *arg, + int from_tty) { target_preopen (from_tty); push_target (target); diff --git a/gdb/inf-child.h b/gdb/inf-child.h index b2692ca..163cab6 100644 --- a/gdb/inf-child.h +++ b/gdb/inf-child.h @@ -34,7 +34,7 @@ extern void store_waitstatus (struct target_waitstatus *, int); the target, in case it need to override to_open. */ extern void inf_child_open_target (struct target_ops *target, - char *arg, int from_tty); + const char *arg, int from_tty); /* To be called by the native target's to_mourn_inferior routine. */