From nobody Thu Aug 15 19:04:59 2024 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WlF1S0TXxz5Sgv5; Thu, 15 Aug 2024 19:05:00 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (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 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WlF1R74HJz4qY2; Thu, 15 Aug 2024 19:04:59 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1723748700; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=2uMIFCfAvg7wDJPCxBSlyx+kCsYBxGze6/LY+UZueQ8=; b=M3Cu0GVakxTSTy9PNlpaEsCIVWlRvHvl4JNPjpDMIKMT62zj7Hyu/owWj2RyhxvA3HKU+l NElQLRkOO6FNXN2MwXKbhLJ79E3P+iO58nqn6A8AdujoefJ0MbJD0gP+T6Eek8JcwvW5OX EX0Hs5v85kS6MjvUU4yGwvnTcoJnKrtZg11jIEaRaaVbw2WT3KIgwYlGNrdg+AWDB27KEU wZBix9MzQ7Sjd68+KiEsYKTRZqeGLnsPBXaxhwBBRD0g8/G2uzy++B0TIuluqM9iVTC4+y x9JeNRQ9bWC6xBOYwRwPVItqnUf0RlYlKFRea9lTJGRHxOusy3a8OwwJIehMTg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1723748700; a=rsa-sha256; cv=none; b=f2xTVUAjTs5CVGJzKGimqo/ZbNOvhe4flAWyeKW0ehhSQohjIdHaLmS/s6E5yflSz+k96J LPg4ewC8G1L6C0a2UJ42IgZlpFWVVlSxKXewMvfPGetahVtVpyam+dL07ALsBmLCZIO/Mz fWOSpKaAVAFAtY52ZnmGZX+91EqE8CwnK0rKTajiI6uT8ppXAsmtmWZ/xUFaQcMaBMSG7q YFEIuE8q+TPcx0SrnQSpLNkLeIJ/f/UyaWN5HIKhci26fyV/SMrP98ei8bR5PX6BLA/yqN 3YXMVYvWs0lotUbZ6DxY3xXtND5b4DPhbH3DQP75TY5b4n923dZEOlot4YxZkg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1723748700; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=2uMIFCfAvg7wDJPCxBSlyx+kCsYBxGze6/LY+UZueQ8=; b=wvl0+S3f6P3buMQjCkZaw6kjfacxe0vwq0xu9SOSj8DzFlfIUpSwtkn8LYTCMhnIBKmJsO ek18ZueaIBt5U30wehjy6S6ul1VZ4Hm3V+Z7KoqaBDWar4UbFnaHz+CQBaRmNd/CSkmyLu DjuBuFUfib/Y+DBXGYXie4xVRGqZmF1DnneKmTZBwy8M8KgwW/tsI0PaCFK0YUxASl+LhJ AwygwVOcxu8liG7XTU7RFBaQWceX9okpahkotFt7gUMI8xynr6Wn7lU5zT+wedpSUkt2+5 8YewdiQAjyyPoCBmZCx6KL/BRhuYLB8odoI7VYZ0saKp3gDzIuM3WG2z1R1cPQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (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) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WlF1R6gtGzZgp; Thu, 15 Aug 2024 19:04:59 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 47FJ4xod091842; Thu, 15 Aug 2024 19:04:59 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 47FJ4xin091839; Thu, 15 Aug 2024 19:04:59 GMT (envelope-from git) Date: Thu, 15 Aug 2024 19:04:59 GMT Message-Id: <202408151904.47FJ4xin091839@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Ed Maste Subject: git: ef9fc9609a1f - main - sys: Mark ACL conversion routines as __result_use_check List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: emaste X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: ef9fc9609a1ff53047577aa7cf51246fc04c954b Auto-Submitted: auto-generated The branch main has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=ef9fc9609a1ff53047577aa7cf51246fc04c954b commit ef9fc9609a1ff53047577aa7cf51246fc04c954b Author: Pierre Pronchery AuthorDate: 2024-08-09 17:37:38 +0000 Commit: Ed Maste CommitDate: 2024-08-15 19:04:29 +0000 sys: Mark ACL conversion routines as __result_use_check Both acl_copy_oldacl_into_acl() and acl_copy_acl_into_oldacl() may fail in some circumstances (e.g., acl.acl_cnt exceeding the capacity of OLDACL_MAX_ENTRIES). This change marks both routines with __result_use_check, enforcing check for errors by the caller. Suggested by: markj Reviewed by: markj, emaste Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D46254 --- sys/sys/acl.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/sys/acl.h b/sys/sys/acl.h index c119cfabef32..d4770667fcf5 100644 --- a/sys/sys/acl.h +++ b/sys/sys/acl.h @@ -309,9 +309,9 @@ void acl_nfs4_compute_inherited_acl( const struct acl *parent_aclp, struct acl *child_aclp, mode_t mode, int file_owner_id, int is_directory); -int acl_copy_oldacl_into_acl(const struct oldacl *source, +int __result_use_check acl_copy_oldacl_into_acl(const struct oldacl *source, struct acl *dest); -int acl_copy_acl_into_oldacl(const struct acl *source, +int __result_use_check acl_copy_acl_into_oldacl(const struct acl *source, struct oldacl *dest); /*