From owner-svn-src-all@freebsd.org Mon Feb 19 21:55:11 2018 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 0C322F01CFB; Mon, 19 Feb 2018 21:55:10 +0000 (UTC) (envelope-from alnsn@yandex.ru) Received: from forward104j.mail.yandex.net (forward104j.mail.yandex.net [IPv6:2a02:6b8:0:801:2::107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "forwards.mail.yandex.net", Issuer "Yandex CA" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 73ABA6D6F0; Mon, 19 Feb 2018 21:55:10 +0000 (UTC) (envelope-from alnsn@yandex.ru) Received: from mxback20j.mail.yandex.net (mxback20j.mail.yandex.net [IPv6:2a02:6b8:0:1619::114]) by forward104j.mail.yandex.net (Yandex) with ESMTP id CF7094182E; Tue, 20 Feb 2018 00:54:59 +0300 (MSK) Received: from smtp2o.mail.yandex.net (smtp2o.mail.yandex.net [2a02:6b8:0:1a2d::26]) by mxback20j.mail.yandex.net (nwsmtp/Yandex) with ESMTP id KoBtvJIf05-sxr8Lqrr; Tue, 20 Feb 2018 00:54:59 +0300 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yandex.ru; s=mail; t=1519077299; bh=lpQiq8iCx0fXeyXsbm8oXD1wa/CLf2znjd7NtyOFIBw=; h=Date:From:To:Cc:Subject:Message-ID:References:In-Reply-To; b=Gea3T7UEnOhPiWCiiwSp0oR+z9bUr+7FIFFUDUoeebohFIh9Yyogshme8PRN9eoQ7 81evMR4q3THFMoGNzpSwvfuwGqabS/06QpL+o/qHf4hloGqK+P3YowVUPvRISgljpY xjYhAw6Irkzp1gm4eQsZ3W/qUboA/I5gfSfkWs9s= Received: by smtp2o.mail.yandex.net (nwsmtp/Yandex) with ESMTPSA id 0hzWNvO8iQ-sveSWbDG; Tue, 20 Feb 2018 00:54:58 +0300 (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client certificate not present) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yandex.ru; s=mail; t=1519077299; bh=lpQiq8iCx0fXeyXsbm8oXD1wa/CLf2znjd7NtyOFIBw=; h=Date:From:To:Cc:Subject:Message-ID:References:In-Reply-To; b=Gea3T7UEnOhPiWCiiwSp0oR+z9bUr+7FIFFUDUoeebohFIh9Yyogshme8PRN9eoQ7 81evMR4q3THFMoGNzpSwvfuwGqabS/06QpL+o/qHf4hloGqK+P3YowVUPvRISgljpY xjYhAw6Irkzp1gm4eQsZ3W/qUboA/I5gfSfkWs9s= Authentication-Results: smtp2o.mail.yandex.net; dkim=pass header.i=@yandex.ru Date: Mon, 19 Feb 2018 21:54:53 +0000 From: Alexander Nasonov To: Kyle Evans Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r329585 - head/stand/lua Message-ID: <20180219215453.GA10409@neva> References: <201802191634.w1JGYNAE003191@repo.freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <201802191634.w1JGYNAE003191@repo.freebsd.org> User-Agent: Mutt/1.9.2 (2017-12-15) X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.25 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, 19 Feb 2018 21:55:11 -0000 Kyle Evans wrote: > +function core.isSingleUserBoot() > + local single_user = loader.getenv("boot_single"); > + return single_user ~= nil and single_user:lower() == "yes"; > +end Just curious, why do you end all lines with semi-colons? It's not very common in Lua code. This version looks more idiomatic: function core.isSingleUserBoot() local single_user = loader.getenv("boot_single") return single_user and single_user:lower() == "yes" end -- Alex