From owner-svn-src-head@FreeBSD.ORG Sun Jun 7 14:06:27 2015 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 0B8C5E4F; Sun, 7 Jun 2015 14:06:27 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from kib.kiev.ua (kib.kiev.ua [IPv6:2001:470:d5e7:1::1]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 767C411C5; Sun, 7 Jun 2015 14:06:26 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from tom.home (kostik@localhost [127.0.0.1]) by kib.kiev.ua (8.14.9/8.14.9) with ESMTP id t57E6Li7094020 (version=TLSv1/SSLv3 cipher=DHE-RSA-CAMELLIA256-SHA bits=256 verify=NO); Sun, 7 Jun 2015 17:06:21 +0300 (EEST) (envelope-from kostikbel@gmail.com) DKIM-Filter: OpenDKIM Filter v2.9.2 kib.kiev.ua t57E6Li7094020 Received: (from kostik@localhost) by tom.home (8.14.9/8.14.9/Submit) id t57E6LPE094019; Sun, 7 Jun 2015 17:06:21 +0300 (EEST) (envelope-from kostikbel@gmail.com) X-Authentication-Warning: tom.home: kostik set sender to kostikbel@gmail.com using -f Date: Sun, 7 Jun 2015 17:06:21 +0300 From: Konstantin Belousov To: Bryan Drewery Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r284105 - head/bin/cp Message-ID: <20150607140621.GI2499@kib.kiev.ua> References: <201506070349.t573ngeh064017@svn.freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <201506070349.t573ngeh064017@svn.freebsd.org> User-Agent: Mutt/1.5.23 (2014-03-12) X-Spam-Status: No, score=-2.0 required=5.0 tests=ALL_TRUSTED,BAYES_00, DKIM_ADSP_CUSTOM_MED,FREEMAIL_FROM,NML_ADSP_CUSTOM_MED autolearn=no autolearn_force=no version=3.4.1 X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on tom.home X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 07 Jun 2015 14:06:27 -0000 On Sun, Jun 07, 2015 at 03:49:42AM +0000, Bryan Drewery wrote: > Author: bdrewery > Date: Sun Jun 7 03:49:41 2015 > New Revision: 284105 > URL: https://svnweb.freebsd.org/changeset/base/284105 > > Log: > Cleanup some indentation issues. > > Modified: > head/bin/cp/utils.c > > Modified: head/bin/cp/utils.c > ============================================================================== > --- head/bin/cp/utils.c Sat Jun 6 22:03:24 2015 (r284104) > +++ head/bin/cp/utils.c Sun Jun 7 03:49:41 2015 (r284105) > @@ -122,18 +122,17 @@ copy_file(const FTSENT *entp, int dne) > /* remove existing destination file name, > * create a new file */ > (void)unlink(to.p_path); > - if (!lflag) > + if (!lflag) { It seems that the next two lines are indented in a funny way as well. > to_fd = open(to.p_path, O_WRONLY | O_TRUNC | O_CREAT, > fs->st_mode & ~(S_ISUID | S_ISGID)); > - } else { > - if (!lflag) > - /* overwrite existing destination file name */ > - to_fd = open(to.p_path, O_WRONLY | O_TRUNC, 0); > - } > - } else { > - if (!lflag) > - to_fd = open(to.p_path, O_WRONLY | O_TRUNC | O_CREAT, > - fs->st_mode & ~(S_ISUID | S_ISGID)); > + } > + } else if (!lflag) { > + /* overwrite existing destination file name */ > + to_fd = open(to.p_path, O_WRONLY | O_TRUNC, 0); > + } > + } else if (!lflag) { > + to_fd = open(to.p_path, O_WRONLY | O_TRUNC | O_CREAT, > + fs->st_mode & ~(S_ISUID | S_ISGID)); > } > > if (to_fd == -1) {