From owner-freebsd-hackers@FreeBSD.ORG Fri Apr 8 16:06:15 2011 Return-Path: Delivered-To: freebsd-hackers@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id AF057106564A for ; Fri, 8 Apr 2011 16:06:15 +0000 (UTC) (envelope-from mike@urgle.com) Received: from anchor-post-1.mail.demon.net (anchor-post-1.mail.demon.net [195.173.77.132]) by mx1.freebsd.org (Postfix) with ESMTP id 78C678FC08 for ; Fri, 8 Apr 2011 16:06:15 +0000 (UTC) Received: from cheddar.urgle.com ([80.177.40.53]) by anchor-post-1.mail.demon.net with esmtp (Exim 4.69) id 1Q8E1p-0004CE-gU; Fri, 08 Apr 2011 15:55:21 +0000 Received: from mike by cheddar.urgle.com with local (Exim 4.75 (FreeBSD)) (envelope-from ) id 1Q8E1o-000Aca-C1; Fri, 08 Apr 2011 15:55:20 +0000 Date: Fri, 8 Apr 2011 16:55:20 +0100 From: Mike Bristow To: Sergey Vinogradov Message-ID: <20110408155520.GA40792@cheddar.urgle.com> References: <4D9EFAC6.4020906@lazybytes.org> <7EA5889E-77EF-4BAE-9655-C33692A75602@bsdimp.com> <4D9F2C88.4010205@lazybytes.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <4D9F2C88.4010205@lazybytes.org> User-Agent: Mutt/1.5.21 (2010-09-15) Cc: FreeBSD Hackers Subject: Re: ifconfig output: ipv4 netmask format X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 08 Apr 2011 16:06:15 -0000 On Fri, Apr 08, 2011 at 07:40:56PM +0400, Sergey Vinogradov wrote: > On 08.04.2011 19:23, Warner Losh wrote: > > On Apr 8, 2011, at 6:08 AM, Sergey Vinogradov wrote: > > If we really wanted to make it human readable, we'd output 10.2.3.4/24 > > So, maybe, while following the POLA, we should add an option, as Daniel > mentioned above? To output the CIDR? Non-contigous netmasks are legal in IPv4. What do you do if someone adds the CIDR flag but the netmask cannot be represented in CIDR notation? Cheers, Mike -- Mike Bristow mike@urgle.com