From owner-svn-src-head@FreeBSD.ORG Fri Jan 23 16:03:03 2015 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id C6976CF; Fri, 23 Jan 2015 16:03:03 +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)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id B2CD8A3D; Fri, 23 Jan 2015 16:03:03 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.9/8.14.9) with ESMTP id t0NG33W9051363; Fri, 23 Jan 2015 16:03:03 GMT (envelope-from will@FreeBSD.org) Received: (from will@localhost) by svn.freebsd.org (8.14.9/8.14.9/Submit) id t0NG33Y3051362; Fri, 23 Jan 2015 16:03:03 GMT (envelope-from will@FreeBSD.org) Message-Id: <201501231603.t0NG33Y3051362@svn.freebsd.org> X-Authentication-Warning: svn.freebsd.org: will set sender to will@FreeBSD.org using -f From: Will Andrews Date: Fri, 23 Jan 2015 16:03:03 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r277567 - head/usr.sbin/config X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 23 Jan 2015 16:03:03 -0000 Author: will Date: Fri Jan 23 16:03:02 2015 New Revision: 277567 URL: https://svnweb.freebsd.org/changeset/base/277567 Log: Allow lists for "nooption" and "nooptions" keywords. usr.sbin/config/config.y According to config(5), the "device", "devices", "nodevice", "nodevices", "option", "options", "nooption", and "nooptions" keywords can all take a comma-separated list of values. However, the yacc code did not allow lists for "nooption" and "nooptions", only single values. This commit fixes the yacc code to allow comma separated values for all the above keywords. Submitted by: asomers MFC after: 1 week Sponsored by: Spectra Logic MFSpectraBSD: 1095296 on 2014/10/07 Modified: head/usr.sbin/config/config.y Modified: head/usr.sbin/config/config.y ============================================================================== --- head/usr.sbin/config/config.y Fri Jan 23 15:55:03 2015 (r277566) +++ head/usr.sbin/config/config.y Fri Jan 23 16:03:02 2015 (r277567) @@ -178,7 +178,7 @@ Config_spec: } | OPTIONS Opt_list | - NOOPTION Save_id { rmopt_schedule(&opt, $2); } | + NOOPTION NoOpt_list | MAKEOPTIONS Mkopt_list | NOMAKEOPTION Save_id { rmopt_schedule(&mkopt, $2); } | @@ -225,6 +225,11 @@ Opt_list: Option ; +NoOpt_list: + NoOpt_list COMMA NoOption + | + NoOption + ; Option: Save_id { newopt(&opt, $1, NULL, 0); @@ -236,6 +241,11 @@ Option: newopt(&opt, $1, $3, 0); } ; +NoOption: + Save_id { + rmopt_schedule(&opt, $1); + }; + Opt_value: ID { $$ = $1; } | NUMBER {