From nobody Fri Feb 02 21:50:21 2024 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4TRTwF3lHPz58Lvy; Fri, 2 Feb 2024 21:50:21 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4TRTwF3FXJz3wwT; Fri, 2 Feb 2024 21:50:21 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1706910621; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=2zURFpwKyBZyom7UptR10Uo6rDCnhGA0i9ZgJthPfY8=; b=sjAHoybF9KTEOEVOUA/lu74owRXsd1pxXnhlh99OcLX5B5E3pEm10NfKqyc0/AuZNyviQg y8U/IrhlPccCO45bS/J81U0KPgcuRsFRPdNXup1LX8fBknKs2ZsaQVjaGfQZzYZR7so12X yCyi4jQDxZW9ycVG11CQ/DlGVBjvEbRR2e72ONXJcN/KPMb3lO/BeRgsLiPEfrPBWX+t8e eWlsT/zp6b8N0AU9jsX3Tr5dJTKhRJUixcelv2UqXFbFuOLoDfJbkf2PPaB4XRFSG4/mfC Bte+VM6qyB+x5XU9rq382URUeVqRMNKtUO3JSouPIed4Fy/rfHDp99fqlsM9FA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1706910621; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=2zURFpwKyBZyom7UptR10Uo6rDCnhGA0i9ZgJthPfY8=; b=Kp6HRCIn47vPuos/JH61yIZ4c2OlYgmEthzKTZIiIrVsfmaCkQQZO2yZ3Tn7hHzlRa34LN ffVGw2UT78olFejxcHzMf1kLs7sIHUSMHDyfxuYi+uM4xZy2QofvVnB+KIzbQzGbOTkSwr pOlYdOUYJ3VmTuoyb9Mv5+15SuUKQzcKPcc/TZq8Fk2TWhrnpfB+liEXyNxviO/TB57etz eYLq26Nnr1iVE97hSjb5hktZJnA7rXTbwXEAOvd/egDQznFtAYrwCuEq3rDuVLkece4yek RmWpnbXW8S9b2At74TvdzOwrd40pg2eNbfCLcA+BbpsWCLoEbHCP3qA21Fdj6g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1706910621; a=rsa-sha256; cv=none; b=LkcREtr5zRrEtS5AkmIGOEOzAIWAfUY6omARX9syfQx0jzf7qAgMBSHzKrhveTs/x5j1nA tkmUD4XzF3rVthzB1nyPguPaj2K/OzR0M9z2fRIKyrXztfA2HLEyMc+jPC4pQq5oV7K0GV /5z3No4s+xm+jJTeDd1PXzHFMvxOpN+mHW60aaxASrDytxWl0/LPMKovE7k6PLg2RASy6w NRAWxichpk6iktjjtlkM2d1tT2Qi5mdsezjn7ae+1rKuZ4/sx6jy5us+hmGDXvXydL/Yd8 bNEx+vBfEOmTuHZSqHwMgahPF5dL/tRwMCCTfEA4tK9Gl2RDO6v3Kssavnl5Qw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4TRTwF2JBxznN4; Fri, 2 Feb 2024 21:50:21 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 412LoLvY033210; Fri, 2 Feb 2024 21:50:21 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 412LoLiw033207; Fri, 2 Feb 2024 21:50:21 GMT (envelope-from git) Date: Fri, 2 Feb 2024 21:50:21 GMT Message-Id: <202402022150.412LoLiw033207@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Warner Losh Subject: git: 0a49be722fe0 - main - traceroute6: remove -l flag List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-main@freebsd.org X-BeenThere: dev-commits-src-main@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 0a49be722fe0cf84c55eb148348499bf66de6ae7 Auto-Submitted: auto-generated The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=0a49be722fe0cf84c55eb148348499bf66de6ae7 commit 0a49be722fe0cf84c55eb148348499bf66de6ae7 Author: Lexi Winter AuthorDate: 2024-02-02 21:46:14 +0000 Commit: Warner Losh CommitDate: 2024-02-02 21:49:13 +0000 traceroute6: remove -l flag The -l flag was used to tell traceroute6(8) to show both hostname and address for each hop. However, traceroute(8) already does this by default, and there's no reason for traceroute6 to behave differently. Make this the default behaviour, and accept -l for backward compatibility as a no-op flag. Reviewed by: imp Pull Request: https://github.com/freebsd/freebsd-src/pull/1023 --- usr.sbin/traceroute6/traceroute6.8 | 11 ++--------- usr.sbin/traceroute6/traceroute6.c | 6 +----- 2 files changed, 3 insertions(+), 14 deletions(-) diff --git a/usr.sbin/traceroute6/traceroute6.8 b/usr.sbin/traceroute6/traceroute6.8 index 13917eb47c7f..1d71895fcde3 100644 --- a/usr.sbin/traceroute6/traceroute6.8 +++ b/usr.sbin/traceroute6/traceroute6.8 @@ -27,7 +27,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd October 25, 2023 +.Dd February 2, 2024 .Dt TRACEROUTE6 8 .Os .\" @@ -120,14 +120,7 @@ tries to use routing headers. .It Fl I Use ICMP6 ECHO instead of UDP datagrams. .It Fl l -Print both host hostnames and numeric addresses. -Normally -.Nm -prints only hostnames if -.Fl n -is not specified, and only numeric addresses if -.Fl n -is specified. +Ignored for backward compatibility. .It Fl m Ar hoplimit Specify maximum hoplimit, up to 255. The default is the value of the diff --git a/usr.sbin/traceroute6/traceroute6.c b/usr.sbin/traceroute6/traceroute6.c index 212564415d6c..15aab51ac234 100644 --- a/usr.sbin/traceroute6/traceroute6.c +++ b/usr.sbin/traceroute6/traceroute6.c @@ -339,7 +339,6 @@ static int verbose; static int waittime = 5; /* time to wait for response (in seconds) */ static int nflag; /* print addresses numerically */ static int useproto = IPPROTO_UDP; /* protocol to use to send packet */ -static int lflag; /* print both numerical address & hostname */ static int as_path; /* print as numbers for each hop */ static int ecnflag; /* ECN bleaching detection flag */ static char *as_server = NULL; @@ -462,7 +461,6 @@ main(int argc, char *argv[]) useproto = IPPROTO_ICMPV6; break; case 'l': - lflag++; break; case 'm': ep = NULL; @@ -1584,10 +1582,8 @@ print(struct msghdr *mhdr, int cc) printf(" [AS%u]", as_lookup(asn, hbuf, AF_INET6)); if (nflag) printf(" %s", hbuf); - else if (lflag) - printf(" %s (%s)", inetname((struct sockaddr *)from), hbuf); else - printf(" %s", inetname((struct sockaddr *)from)); + printf(" %s (%s)", inetname((struct sockaddr *)from), hbuf); if (verbose) { #ifdef OLDRAWSOCKET