From owner-freebsd-current@FreeBSD.ORG Mon Aug 21 16:37:57 2006 Return-Path: X-Original-To: freebsd-current@freebsd.org Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 4ABB216A4DF for ; Mon, 21 Aug 2006 16:37:57 +0000 (UTC) (envelope-from rnsanchez@gmail.com) Received: from wr-out-0506.google.com (wr-out-0506.google.com [64.233.184.224]) by mx1.FreeBSD.org (Postfix) with ESMTP id 72E0643D4C for ; Mon, 21 Aug 2006 16:37:56 +0000 (GMT) (envelope-from rnsanchez@gmail.com) Received: by wr-out-0506.google.com with SMTP id 70so263211wra for ; Mon, 21 Aug 2006 09:37:55 -0700 (PDT) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:date:from:to:cc:subject:message-id:in-reply-to:references:x-mailer:mime-version:content-type:content-transfer-encoding; b=RuIcT4EkLrHZgG3v2XOwQ7ZSt1HAhYiiiGns1A2qNlaEDzQj+L3tYscaClRmIviGglo0wVpylOMxgL4gf+nnYIbTEQjTXwQE0szOBaLQghbUawhB3auZJ2P3kjJzGfybEMoRY05auKHGZe6hWOWiR6jgs2FUdxxzOL5LmdlJsE4= Received: by 10.90.105.19 with SMTP id d19mr176045agc; Mon, 21 Aug 2006 09:37:55 -0700 (PDT) Received: from sauron.lan.box ( [201.3.138.62]) by mx.gmail.com with ESMTP id 33sm249289wra.2006.08.21.09.37.54; Mon, 21 Aug 2006 09:37:55 -0700 (PDT) Date: Mon, 21 Aug 2006 13:37:50 -0300 From: Ricardo Nabinger Sanchez To: Thomas Quinot Message-Id: <20060821133750.ab3143a9.rnsanchez@gmail.com> In-Reply-To: <20060821071945.GA75839@melamine.cuivre.fr.eu.org> References: <20060821002856.601c8dfd.rnsanchez@gmail.com> <20060821071945.GA75839@melamine.cuivre.fr.eu.org> X-Mailer: Sylpheed version 2.2.7 (GTK+ 2.8.20; i386-portbld-freebsd6.1) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Cc: freebsd-current@freebsd.org Subject: Re: [RFC] (very) small ifmedia.c cleanup 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: Mon, 21 Aug 2006 16:37:57 -0000 Hello, On Mon, 21 Aug 2006 09:19:45 +0200, Thomas Quinot wrote: > > I was looking at src/sbin/ifconfig/ifmedia.c source, and noticed that > > the handling of IFM_ETHER and IFM_ATM was identical. Also noticed the > > use of goto that, IMHO, could be clearer if made with a plain if (), > > very similar to the condition a few lines above each occurence of the > > gotos. > > Looks good to me. The more factoring, the merrier! I think you could even > push things a little further and aggressively factor what can be factored > between print_media_word and print_media_word_ifconfig. Thanks for your comments -- I'll surely check what can I do considering your suggestion, and this time will fill a PR. > > > Now I'm wondering if this diff looks good, as it is a first one I'm > > sending over here. The send-pr(1) seemed to be just too much noise, > > but if that's the correct way, please let me know. The diff is against > > -current. > > It never hurts to submit a PR, it helps keeping track of the discussion > of a patch, the commit, and any possible subsequent action. Then I'll submit a PR for this one. Thanks again :) -- Ricardo Nabinger Sanchez Powered by FreeBSD "Left to themselves, things tend to go from bad to worse."