From owner-svn-src-all@FreeBSD.ORG Tue Feb 18 14:54:56 2014 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id DAB519F; Tue, 18 Feb 2014 14:54:56 +0000 (UTC) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id C66511D50; Tue, 18 Feb 2014 14:54:56 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.8/8.14.8) with ESMTP id s1IEsup1096096; Tue, 18 Feb 2014 14:54:56 GMT (envelope-from jonathan@svn.freebsd.org) Received: (from jonathan@localhost) by svn.freebsd.org (8.14.8/8.14.8/Submit) id s1IEsuVN096094; Tue, 18 Feb 2014 14:54:56 GMT (envelope-from jonathan@svn.freebsd.org) Message-Id: <201402181454.s1IEsuVN096094@svn.freebsd.org> From: Jonathan Anderson Date: Tue, 18 Feb 2014 14:54:56 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r262166 - head/sys/sys X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 Feb 2014 14:54:56 -0000 Author: jonathan Date: Tue Feb 18 14:54:56 2014 New Revision: 262166 URL: http://svnweb.freebsd.org/changeset/base/262166 Log: Add more __BEGIN_DECLS / __END_DECLS to . capability.h currently only wraps some of its declarations in __BEGIN_DECLS/__END_DECLS, so cap_enter(), cap_sandboxed(), etc. are usable from C++ code but cap_rights_init(), cap_rights_is_valid() etc. are not. This commit fixes this distinction. Approved by: rwatson (mentor) MFC after: 1 week Sponsored by: DARPA, AFRL Modified: head/sys/sys/capability.h Modified: head/sys/sys/capability.h ============================================================================== --- head/sys/sys/capability.h Tue Feb 18 14:53:36 2014 (r262165) +++ head/sys/sys/capability.h Tue Feb 18 14:54:56 2014 (r262166) @@ -315,6 +315,8 @@ #define CAP_IOCTLS_ALL SSIZE_MAX +__BEGIN_DECLS + #define cap_rights_init(...) \ __cap_rights_init(CAP_RIGHTS_VERSION, __VA_ARGS__, 0ULL) cap_rights_t *__cap_rights_init(int version, cap_rights_t *rights, ...); @@ -336,6 +338,8 @@ cap_rights_t *cap_rights_merge(cap_right cap_rights_t *cap_rights_remove(cap_rights_t *dst, const cap_rights_t *src); bool cap_rights_contains(const cap_rights_t *big, const cap_rights_t *little); +__END_DECLS + #ifdef _KERNEL #include