From patchwork Sun Jan 16 18:52:47 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Samuel Thibault X-Patchwork-Id: 1580509 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=sourceware.org (client-ip=2620:52:3:1:0:246e:9693:128c; helo=sourceware.org; envelope-from=libc-alpha-bounces+incoming=patchwork.ozlabs.org@sourceware.org; receiver=) Received: from sourceware.org (server2.sourceware.org [IPv6:2620:52:3:1:0:246e:9693:128c]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by bilbo.ozlabs.org (Postfix) with ESMTPS id 4JcPLS5Xrkz9sRR for ; Mon, 17 Jan 2022 05:53:04 +1100 (AEDT) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 0D3413858427 for ; Sun, 16 Jan 2022 18:53:00 +0000 (GMT) X-Original-To: libc-alpha@sourceware.org Delivered-To: libc-alpha@sourceware.org Received: from hera.aquilenet.fr (hera.aquilenet.fr [IPv6:2a0c:e300::1]) by sourceware.org (Postfix) with ESMTPS id 815513858402 for ; Sun, 16 Jan 2022 18:52:51 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 815513858402 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=ens-lyon.org Authentication-Results: sourceware.org; spf=fail smtp.mailfrom=ens-lyon.org Received: from localhost (localhost [127.0.0.1]) by hera.aquilenet.fr (Postfix) with ESMTP id 4B5C4427; Sun, 16 Jan 2022 19:52:50 +0100 (CET) X-Virus-Scanned: Debian amavisd-new at aquilenet.fr Received: from hera.aquilenet.fr ([127.0.0.1]) by localhost (hera.aquilenet.fr [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id Rqp2lA11JwDg; Sun, 16 Jan 2022 19:52:49 +0100 (CET) Received: from begin (unknown [IPv6:2a01:cb19:956:1b00:de41:a9ff:fe47:ec49]) by hera.aquilenet.fr (Postfix) with ESMTPSA id 9CF8E205; Sun, 16 Jan 2022 19:52:49 +0100 (CET) Received: from samy by begin with local (Exim 4.95) (envelope-from ) id 1n9Adz-005s84-UG; Sun, 16 Jan 2022 19:52:47 +0100 From: Samuel Thibault To: libc-alpha@sourceware.org Subject: [hurd,commited] hurd: Make RPC input array parameters const Date: Sun, 16 Jan 2022 19:52:47 +0100 Message-Id: <20220116185247.1399705-1-samuel.thibault@ens-lyon.org> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 X-Spamd-Bar: ++++ X-Rspamd-Server: hera Authentication-Results: hera.aquilenet.fr; none X-Rspamd-Queue-Id: 4B5C4427 X-Spamd-Result: default: False [4.90 / 15.00]; ARC_NA(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; FROM_HAS_DN(0.00)[]; RCPT_COUNT_THREE(0.00)[3]; TO_DN_SOME(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[text/plain]; R_MISSING_CHARSET(2.50)[]; BROKEN_CONTENT_TYPE(1.50)[]; RCVD_COUNT_THREE(0.00)[3]; MID_CONTAINS_FROM(1.00)[]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_LAST(0.00)[] X-Spam-Status: No, score=-11.8 required=5.0 tests=BAYES_00, GIT_PATCH_0, JMQ_SPF_NEUTRAL, KAM_DMARC_STATUS, SPF_HELO_PASS, SPF_NEUTRAL, TXREP autolearn=ham autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on server2.sourceware.org X-BeenThere: libc-alpha@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libc-alpha mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: commit-hurd@gnu.org Errors-To: libc-alpha-bounces+incoming=patchwork.ozlabs.org@sourceware.org Sender: "Libc-alpha" This follows mig's cf4bcc3f1435 ("Also add const qualifiers on server side") --- hurd/hurdauth.c | 4 ++-- hurd/hurdmsg.c | 14 +++++++------- hurd/report-wait.c | 2 +- 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/hurd/hurdauth.c b/hurd/hurdauth.c index e602179a3f..9086e9484c 100644 --- a/hurd/hurdauth.c +++ b/hurd/hurdauth.c @@ -165,8 +165,8 @@ _S_msg_add_auth (mach_port_t me, kern_return_t _S_msg_del_auth (mach_port_t me, task_t task, - intarray_t uids, mach_msg_type_number_t nuids, - intarray_t gids, mach_msg_type_number_t ngids) + const_intarray_t uids, mach_msg_type_number_t nuids, + const_intarray_t gids, mach_msg_type_number_t ngids) { error_t err; auth_t newauth; diff --git a/hurd/hurdmsg.c b/hurd/hurdmsg.c index 4e6ddf2836..cad8300968 100644 --- a/hurd/hurdmsg.c +++ b/hurd/hurdmsg.c @@ -93,7 +93,7 @@ _S_msg_get_init_ports (mach_port_t msgport, mach_port_t auth, kern_return_t _S_msg_set_init_ports (mach_port_t msgport, mach_port_t auth, - mach_port_t *ports, mach_msg_type_number_t nports) + const mach_port_t *ports, mach_msg_type_number_t nports) { mach_msg_type_number_t i; error_t err; @@ -243,7 +243,7 @@ _S_msg_set_init_int (mach_port_t msgport, mach_port_t auth, kern_return_t _S_msg_set_init_ints (mach_port_t msgport, mach_port_t auth, - int *values, mach_msg_type_number_t nvalues) + const int *values, mach_msg_type_number_t nvalues) { error_t err; mach_msg_type_number_t i; @@ -295,7 +295,7 @@ _S_msg_set_fd (mach_port_t msgport, mach_port_t auth, kern_return_t _S_msg_get_env_variable (mach_port_t msgport, - string_t variable, // + const_string_t variable, // char **data, mach_msg_type_number_t *datalen) { error_t err; @@ -322,8 +322,8 @@ _S_msg_get_env_variable (mach_port_t msgport, kern_return_t _S_msg_set_env_variable (mach_port_t msgport, mach_port_t auth, - string_t variable, // - string_t value, // + const_string_t variable, // + const_string_t value, // int replace) { AUTHCHECK; @@ -367,7 +367,7 @@ _S_msg_get_environment (mach_port_t msgport, kern_return_t _S_msg_set_environment (mach_port_t msgport, mach_port_t auth, - char *data, mach_msg_type_number_t datalen) + const char *data, mach_msg_type_number_t datalen) { int _hurd_split_args (char *, mach_msg_type_number_t, char **); int envc; @@ -441,6 +441,6 @@ out: kern_return_t _S_msg_set_dtable (mach_port_t process, mach_port_t refport, - portarray_t dtable, + const_portarray_t dtable, mach_msg_type_number_t dtableCnt) { return EOPNOTSUPP; } diff --git a/hurd/report-wait.c b/hurd/report-wait.c index 49f38bff07..676a34a480 100644 --- a/hurd/report-wait.c +++ b/hurd/report-wait.c @@ -234,7 +234,7 @@ _S_msg_report_wait (mach_port_t msgport, thread_t thread, kern_return_t _S_msg_describe_ports (mach_port_t msgport, mach_port_t refport, - mach_port_t *ports, mach_msg_type_number_t nports, + const mach_port_t *ports, mach_msg_type_number_t nports, char **desc, mach_msg_type_number_t *desclen) { char *p, *end;