ed; d=freebsd.org; s=dkim; t=1734360308; 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=xID18P8s1twDmP5UHsWgaEnDg7qP/LqtMOjqOG+GQmU=; b=t5m4Jm9Rp2gPognBuA1rABNFQtjCjdXoysjD+Tnzl/LQREbGeAYQbg5oNviTeCxX5uTTwf 99DuRDqF0gppRjvLm4ofZuY5S1rr2C5hnhRxUPwaYMk0msaJ1GPEzsJkYuadbLzSdEF41a W5GiI+U+MlOTPl9yAwtSnB9vLjCMFAsOc1+6oUNOHU9B78CTJhDdyZlo/dApPOUr/S2zk3 dJBjG4X686ABqi52adaMVWhxOX1vcv7FjGOeTH1A+FqVmAZOOBPKn33BeJLd5nvrnvzLuP yoOIfrVycABuXZZPX4lK2ryofx0LWenqMz8vhkgi6wFqYuBcWSiVsJPAl/rIcA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1734360308; a=rsa-sha256; cv=none; b=ILFScktOhCUWXAtlpOeT/9nBW2WuVlbQel7SPsMIEvPzjXy0n3jZ5wvYJMr0hC0FJ+fmPx 9YCEXRdsjgbPptUdNfEs2EPBh/UapzQw03RsMN/3w7eRiAgCKK6zmrcS3SLb8U63Spfah0 1scm9ybCcl9F15NMzVwnf3TyRrjhHFOTmk3xUCpZp01ayIXM4XU30WQMAe9R2hkoapaAet se/BJMen8EqRm8wQm8rK5dLFsOEK0ue/BOV6TKukFtJFF1XDll5ma4GDeK/3enecHHwZpY t/ZT2swcXzP/fq7WbbC8LTQOydCGOTxNnJZJzMwRqwLQW10T311cgezdQBPBvg== 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 4YBjQr0KWRzxWk; Mon, 16 Dec 2024 14:45:08 +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 4BGEj7CE051109; Mon, 16 Dec 2024 14:45:07 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BGEj7T9051106; Mon, 16 Dec 2024 14:45:07 GMT (envelope-from git) Date: Mon, 16 Dec 2024 14:45:07 GMT Message-Id: <202412161445.4BGEj7T9051106@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Olivier Certner Subject: git: 5140ccf2268b - main - MAC: mac.h: Fix missing includes/typedefs 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: olce X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 5140ccf2268b0e771c89e46f46c60e1fee7637c3 Auto-Submitted: auto-generated The branch main has been updated by olce: URL: https://cgit.FreeBSD.org/src/commit/?id=5140ccf2268b0e771c89e46f46c60e1fee7637c3 commit 5140ccf2268b0e771c89e46f46c60e1fee7637c3 Author: Olivier Certner AuthorDate: 2024-07-29 14:21:52 +0000 Commit: Olivier Certner CommitDate: 2024-12-16 14:42:26 +0000 MAC: mac.h: Fix missing includes/typedefs This fixes inclusion from userspace, and also kernel inclusion for source files not including explicitly nor implicitly . Reviewed by: jamie Approved by: markj (mentor) MFC after: 5 days Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D46896 --- sys/sys/mac.h | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/sys/sys/mac.h b/sys/sys/mac.h index facdc14c332d..ae8d8d38f17b 100644 --- a/sys/sys/mac.h +++ b/sys/sys/mac.h @@ -47,6 +47,13 @@ #ifndef _SYS_MAC_H_ #define _SYS_MAC_H_ +#include + +#ifndef _SIZE_T_DECLARED +typedef __size_t size_t; +#define _SIZE_T_DECLARED +#endif + #ifndef _POSIX_MAC #define _POSIX_MAC #endif @@ -72,6 +79,13 @@ typedef struct mac *mac_t; #ifndef _KERNEL +#include /* For __BEGIN_DECLS and __END_DECLS. */ + +#ifndef _PID_T_DECLARED +typedef __pid_t pid_t; /* process id */ +#define _PID_T_DECLARED +#endif + /* * Location of the userland MAC framework configuration file. mac.conf * set defaults for MAC-aware applications.