From owner-svn-src-all@FreeBSD.ORG Mon Jun 27 09:14:25 2011 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 7CCA61065672; Mon, 27 Jun 2011 09:14:25 +0000 (UTC) (envelope-from pjd@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 6DF408FC18; Mon, 27 Jun 2011 09:14:25 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id p5R9EP5B089906; Mon, 27 Jun 2011 09:14:25 GMT (envelope-from pjd@svn.freebsd.org) Received: (from pjd@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id p5R9EPlQ089904; Mon, 27 Jun 2011 09:14:25 GMT (envelope-from pjd@svn.freebsd.org) Message-Id: <201106270914.p5R9EPlQ089904@svn.freebsd.org> From: Pawel Jakub Dawidek Date: Mon, 27 Jun 2011 09:14:25 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r223585 - head/sbin/hastd X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 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: Mon, 27 Jun 2011 09:14:25 -0000 Author: pjd Date: Mon Jun 27 09:14:25 2011 New Revision: 223585 URL: http://svn.freebsd.org/changeset/base/223585 Log: Compile capsicum support only if HAVE_CAPSICUM is defined. MFC after: 3 days Modified: head/sbin/hastd/subr.c Modified: head/sbin/hastd/subr.c ============================================================================== --- head/sbin/hastd/subr.c Mon Jun 27 09:10:48 2011 (r223584) +++ head/sbin/hastd/subr.c Mon Jun 27 09:14:25 2011 (r223585) @@ -31,7 +31,9 @@ #include __FBSDID("$FreeBSD$"); +#ifdef HAVE_CAPSICUM #include +#endif #include #include #include @@ -230,6 +232,7 @@ drop_privs(struct hast_resource *res) * ioctls and secondary uses ioctls to handle BIO_DELETE and BIO_FLUSH. * For now capsicum is only used to sandbox hastctl. */ +#ifdef HAVE_CAPSICUM if (res == NULL) { capsicum = (cap_enter() == 0); if (!capsicum) { @@ -237,6 +240,7 @@ drop_privs(struct hast_resource *res) "Unable to sandbox using capsicum"); } } else +#endif capsicum = false; /*