From owner-svn-src-all@FreeBSD.ORG Wed Feb 5 01:29:14 2014 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id B7F8CB7D for ; Wed, 5 Feb 2014 01:29:14 +0000 (UTC) Received: from mail-qa0-x232.google.com (mail-qa0-x232.google.com [IPv6:2607:f8b0:400d:c00::232]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 6C8AB1373 for ; Wed, 5 Feb 2014 01:29:14 +0000 (UTC) Received: by mail-qa0-f50.google.com with SMTP id cm18so13393047qab.37 for ; Tue, 04 Feb 2014 17:29:13 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=eitanadler.com; s=0xdeadbeef; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to:cc:content-type; bh=NY+xQISBiInJmIXLrtAn1+/kwRc49T3N2hv80E1siUs=; b=kZ/aqkFDqA6uI+8ehgEh+Vt55+3J0w6V2fb9Alc+zIH5XBedjFIhz/wAoTg45GM2+p HbPg7IW+q9OlOuq6OLdzAKNqQnenD3Ia6ojCz306AfL6SQNucHv8V71PxE8e8lBmNj4K rGyGPPq3wseQjhsYClxv7MA+f6Fq/ZTUf69pM= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:sender:in-reply-to:references:from :date:message-id:subject:to:cc:content-type; bh=NY+xQISBiInJmIXLrtAn1+/kwRc49T3N2hv80E1siUs=; b=O250uhpKh0InebrhOTW6yPXy5QOQ8W64JGtk9VTlahSyymalSpEReee2bAJM9Abc8a Iyaw2SI4QVd0dfdmDtkAXYudJpW4DANPJwCM8z+qC5WGfnYk7lZl/39XZBb6rNZK8sLH GeKYyNmXwMlL2fmORGmETFusgUV1PELSUqQ3BhwRvHmLqSLJ4utbairqhdeziPB0zyf9 216nXKSPtzkXiwfx2gAhmQNi1Gktv0CbIKTTn918ss/D+rv4QcMEjr8fP5A1U6Z6zhGr yxTxch+Pu92P0YbtFcgTempCQlF9j8vxLAQxuBmEORWds7/hswb6XdXMU4a3DILRcUuo vVPw== X-Gm-Message-State: ALoCoQl59aGojIYS/ljGXFoIS8+D/sLMFuBERHpRtFnczge22mL38hOWE6zH8Y4qXLqiStKthTRQ X-Received: by 10.140.85.179 with SMTP id n48mr66436402qgd.91.1391563753594; Tue, 04 Feb 2014 17:29:13 -0800 (PST) MIME-Version: 1.0 Sender: lists@eitanadler.com Received: by 10.96.30.229 with HTTP; Tue, 4 Feb 2014 17:28:43 -0800 (PST) In-Reply-To: <20140204164703.S1229@besplex.bde.org> References: <201402040301.s1431XgK027156@svn.freebsd.org> <20140204164703.S1229@besplex.bde.org> From: Eitan Adler Date: Tue, 4 Feb 2014 20:28:43 -0500 X-Google-Sender-Auth: kyXFJjX8KJYyked4A1Qq13oeo14 Message-ID: Subject: Re: svn commit: r261454 - head/lib/libc/net To: Bruce Evans Content-Type: text/plain; charset=UTF-8 Cc: "svn-src-head@freebsd.org" , "svn-src-all@freebsd.org" , "src-committers@freebsd.org" 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: Wed, 05 Feb 2014 01:29:14 -0000 On Tue, Feb 4, 2014 at 1:29 AM, Bruce Evans wrote: > On Tue, 4 Feb 2014, Eitan Adler wrote: > >> Log: >> libc/net: Fix some issues in inet6_opt_init() (from RFC 3542): >> >> * The RFC says (in section 10.1) that only when extbuf is not NULL, >> extlen shall be checked, so don't perform this check when NULL is >> passed. >> >> * socklen_t is unsigned, so checking extlen for less than zero is >> not needed. > > > Why be so unportable? socklen_t is not necessarily unsigned. When I checked prior to commit I read ' makes available a type, socklen_t, which is an unsigned opaque integral type of length of at least 32 bits. ' After checking again it turns out that this quote is from SUSv2 which is just a bit old. In any case switching the line to <= 0 won't add any real value now. -- Eitan Adler Source, Ports, Doc committer Bugmeister, Ports Security teams