From owner-freebsd-current@FreeBSD.ORG Fri Dec 5 07:22:30 2008 Return-Path: Delivered-To: current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id AFFB9106564A for ; Fri, 5 Dec 2008 07:22:30 +0000 (UTC) (envelope-from ed@hoeg.nl) Received: from palm.hoeg.nl (mx0.hoeg.nl [IPv6:2001:7b8:613:100::211]) by mx1.freebsd.org (Postfix) with ESMTP id 4D0588FC16 for ; Fri, 5 Dec 2008 07:22:30 +0000 (UTC) (envelope-from ed@hoeg.nl) Received: by palm.hoeg.nl (Postfix, from userid 1000) id 4B0F41CD5F; Fri, 5 Dec 2008 08:22:29 +0100 (CET) Date: Fri, 5 Dec 2008 08:22:29 +0100 From: Ed Schouten To: Maksim Yevmenkin Message-ID: <20081205072229.GE18652@hoeg.nl> References: <7d6fde3d0812040324y3bf0901cy1f4a6d961362c314@mail.gmail.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="bi5JUZtvcfApsciF" Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.18 (2008-05-17) Cc: Garrett Cooper , "current@freebsd.org" Subject: Re: RFC: small syscons and kbd patch X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 05 Dec 2008 07:22:30 -0000 --bi5JUZtvcfApsciF Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable * Maksim Yevmenkin wrote: > the idea was to ensure that kbd->kb_locked variable only takes values > 0 (zero) and 1 (one). I often use constructs like these to do that: foo =3D bar ? 1 : 0; Maybe !!bar is a lot shorter to write, I think the line above is a lot easier to read. --=20 Ed Schouten WWW: http://80386.nl/ --bi5JUZtvcfApsciF Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (FreeBSD) iEYEARECAAYFAkk41rUACgkQ52SDGA2eCwU0XgCfTz6PnSH226WpjEt0xx8JeyZl t6kAmwQHRIde8oeSuDQH2oLHTCpTqUGR =exJ0 -----END PGP SIGNATURE----- --bi5JUZtvcfApsciF--