From owner-svn-src-all@freebsd.org Mon Aug 31 18:58:12 2020 Return-Path: Delivered-To: svn-src-all@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id E1E803CA757; Mon, 31 Aug 2020 18:58:12 +0000 (UTC) (envelope-from carpeddiem@gmail.com) Received: from mail-io1-f45.google.com (mail-io1-f45.google.com [209.85.166.45]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1O1" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4BgKGX4Lryz3gFk; Mon, 31 Aug 2020 18:58:12 +0000 (UTC) (envelope-from carpeddiem@gmail.com) Received: by mail-io1-f45.google.com with SMTP id b16so7169981ioj.4; Mon, 31 Aug 2020 11:58:12 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=vsJq1+xCxeoZnNY7RRc7G/ERkIM2cseLusO9FcdNgK8=; b=FKgMEgvHjX6pDlb89OQXpn/by/ONoK2NHbO3Ge/YenEGVZPCbKMQ77CkC1q0/I4XPW QLD6JD7uXSHzISr8ru+YbN/ieG7zT1nJ6AbcVeZeOervoRFlR4qllsDA71gSFqXlc6QE TQgp4Ep6qxMbc3wx5OhLyoImd0je3V7rL1DU46mg9tu0F0PFQmX5wpOIp5oxVpqIHvzj iaFFLcpTxA8EcOmIkkHkRBNUzv9uHjEfyKN4H0BZykodKLJZJvCdwgAvHZtQlxgMcT3f 2i7AQGT5uKGSRVBRQeejrBQI3uJeFV/Kr07iuQTczMt/zZlObYhBh+wpnHa2NSOgvSTx 3Riw== X-Gm-Message-State: AOAM530xwW7Ic3z7op2xR2hMPtlFLSKMdSQZ1M//VHG3Yw/qQBAwTnMb Pz7L5mBYRguTAs93ZUyhubM7hscjGsXo52qwIwKU05gL X-Google-Smtp-Source: ABdhPJyS596x9KXYfBEixNfhwVnJqu6MJNBFeIlZtBVrPyyQRkZBiprSZk/MW6/b4dU7rf+hSzOgqmXN9VK5HCByD8I= X-Received: by 2002:a02:85e1:: with SMTP id d88mr2585149jai.8.1598900290559; Mon, 31 Aug 2020 11:58:10 -0700 (PDT) MIME-Version: 1.0 References: <202008311409.07VE9Ch9033206@gndrsh.dnsmgr.net> In-Reply-To: <202008311409.07VE9Ch9033206@gndrsh.dnsmgr.net> From: Ed Maste Date: Mon, 31 Aug 2020 14:57:58 -0400 Message-ID: Subject: Re: svn commit: r364321 - head/sbin/ipfw To: "Rodney W. Grimes" Cc: src-committers , svn-src-all , svn-src-head Content-Type: text/plain; charset="UTF-8" X-Rspamd-Queue-Id: 4BgKGX4Lryz3gFk X-Spamd-Bar: ---- Authentication-Results: mx1.freebsd.org; none X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[]; ASN(0.00)[asn:15169, ipnet:209.85.128.0/17, country:US] X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.33 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: Mon, 31 Aug 2020 18:58:12 -0000 On Mon, 31 Aug 2020 at 10:09, Rodney W. Grimes wrote: > > > Hrm, it seems this reply ended up in my spam folder; sorry for not > > replying until now. > > lol Oh, bad filter :-) > > > > > *strchr(timestr, '\n') = '\0'; > > > > bprintf(bp, "%s ", timestr); > > > ^ Isnt this the +1 space? > > > > > > > } else { > > > > - bprintf(bp, "%*s", twidth, " "); > > > > + bprintf(bp, "%*s", twidth + 1, " "); > > > ^missing from this string? > > > > Inserting an extra space in the format string would also work, sure. I > > considered doing it that way but in the end decided it's not > > materially more clear one way or another, so used the patch as > > submitted. > > For me the + 1 leads to a "why is this here", where as the space > in the format string clearly matches the other condition of the else. > Also + 1 causes a run time computation, the extra space does not. No, but the extra space adds a format string character which will be more costly than the +1. I would have used "%*s " if twidth was already used in the other case, to keep them consistent. Anyhow, I think this isn't worth bikeshedding; I have no objection if anyone feels "%*s " is more clear and wants to commit that change.