From owner-svn-src-all@freebsd.org Sun Aug 9 11:51:27 2015 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id F35C299D08D for ; Sun, 9 Aug 2015 11:51:27 +0000 (UTC) (envelope-from ed@nuxi.nl) Received: from mail-oi0-f48.google.com (mail-oi0-f48.google.com [209.85.218.48]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id C5463AD7 for ; Sun, 9 Aug 2015 11:51:26 +0000 (UTC) (envelope-from ed@nuxi.nl) Received: by oip136 with SMTP id 136so73841703oip.1 for ; Sun, 09 Aug 2015 04:51:25 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=fYUhINffG50hOl9RyPAQb50tTLo9tTuOGYj89DXAqRc=; b=JfZRVgCkcydklK+r2zssmOGzsi+Qv1X5oaQK79hxQSYB26lGx8ufo/DQsNvHCgarOD K6f62vH8UWcLrMTD4onXLpePd3nRvGT3asudRFn8u3hrkizk7kO7z8Esx6Md32y4gRGe UwsjKmXU1Ros5MritkcI1upariXUtWnj1/u64sdf8cmvBXkhKq/a0gXZ7AxulRQsQuX5 IcLzgWoZnZnQ0nDP2+amLTPQ80Q8b3hTK6YD4XtTJmBdVx3+BxhsL42Yp3Td2/eGXBNR 4rlOQABqR/ZfqBAPS13Gfa+OxNH64L0CACTfi38G+l/B35yRZgw7TesgJQBQOUICflwG dm1g== X-Gm-Message-State: ALoCoQkkhw0XA3DSMIHRLnZokjRjaHd7EqRDvoWnz7RXvt7uIVsj/2ysf9KkFzNcQuNRNCr5gY16 MIME-Version: 1.0 X-Received: by 10.202.67.67 with SMTP id q64mr14694357oia.124.1439121085579; Sun, 09 Aug 2015 04:51:25 -0700 (PDT) Received: by 10.76.50.84 with HTTP; Sun, 9 Aug 2015 04:51:25 -0700 (PDT) X-Originating-IP: [84.27.222.46] In-Reply-To: <201508040234.t742YqQA045448@repo.freebsd.org> References: <201508040234.t742YqQA045448@repo.freebsd.org> Date: Sun, 9 Aug 2015 13:51:25 +0200 Message-ID: Subject: Re: svn commit: r286266 - head/usr.bin/ypmatch From: Ed Schouten To: Marcelo Araujo Cc: src-committers , svn-src-all@freebsd.org, svn-src-head@freebsd.org Content-Type: text/plain; charset=UTF-8 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.20 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: Sun, 09 Aug 2015 11:51:28 -0000 Hi Marcelo, 2015-08-04 4:34 GMT+02:00 Marcelo Araujo : > Sync the code with the OpenBSD version. That's a shame. It looks like improvements that we made to our version have been undone because of this. > -static void > +void > usage(void) This function could be static. > + fprintf(stderr, > + "where\n" > + "\tmapname may be either a mapname or a nickname for a map.\n" > + "\t-k prints keys as well as values.\n" > + "\t-t inhibits map nickname translation.\n" > + "\t-x dumps the map nickname translation table.\n"); It is fairly uncommon for BSD utilities to have an extensive help output. Man pages are intended for that purpose. > - while ((c = getopt(argc, argv, "xd:kt")) != -1) > + while ((c=getopt(argc, argv, "xd:kt")) != -1) > switch (c) { > case 'x': > - for (i = 0; i + for (i=0; i ... > - if ((argc-optind) < 2) > + if ((argc-optind) < 2 ) > ... > - if (!domainname) > + if (!domainname) { > yp_get_default_domain(&domainname); > + } Though the style(9) conformance of tool wasn't ideal, this change made it worse. -- Ed Schouten Nuxi, 's-Hertogenbosch, the Netherlands KvK/VAT number: 62051717