Date: Fri, 19 Dec 2025 14:13:20 +0000 From: Mark Johnston <markj@FreeBSD.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Subject: git: 7080c1b09d72 - main - tests: Fix style in ra.py Message-ID: <69455d80.3c918.383f8f8a@gitrepo.freebsd.org>
index | next in thread | raw e-mail
The branch main has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=7080c1b09d72e64f17185e90d7b660175f8fbaba commit 7080c1b09d72e64f17185e90d7b660175f8fbaba Author: Mark Johnston <markj@FreeBSD.org> AuthorDate: 2025-12-19 14:11:01 +0000 Commit: Mark Johnston <markj@FreeBSD.org> CommitDate: 2025-12-19 14:11:01 +0000 tests: Fix style in ra.py No functional change intended. MFC after: 2 weeks --- tests/sys/netinet6/ra.py | 22 ++++++++++++---------- 1 file changed, 12 insertions(+), 10 deletions(-) diff --git a/tests/sys/netinet6/ra.py b/tests/sys/netinet6/ra.py index 44814418da48..a5016b3f6e9b 100644 --- a/tests/sys/netinet6/ra.py +++ b/tests/sys/netinet6/ra.py @@ -1,4 +1,4 @@ -#- +# # SPDX-License-Identifier: BSD-2-Clause # # Copyright (c) 2024 Klara, Inc. @@ -8,31 +8,33 @@ import argparse import scapy.all as sp import sys + # # Emit a router advertisement with the specified prefix. # def main(): parser = argparse.ArgumentParser("ra.py", - description="Emits Router Advertisement packets") + description="Emits Router Advertisement packets") parser.add_argument('--sendif', nargs=1, required=True, - help='The interface through which the packet will be sent') + help='The interface through which the packet will be sent') parser.add_argument('--src', nargs=1, required=True, - help='The source IP address') + help='The source IP address') parser.add_argument('--dst', nargs=1, required=True, - help='The destination IP address') + help='The destination IP address') parser.add_argument('--prefix', nargs=1, required=True, - help='The prefix to be advertised') + help='The prefix to be advertised') parser.add_argument('--prefixlen', nargs=1, required=True, type=int, - help='The prefix length to be advertised') + help='The prefix length to be advertised') args = parser.parse_args() pkt = sp.Ether() / \ - sp.IPv6(src=args.src, dst=args.dst) / \ - sp.ICMPv6ND_RA(chlim=64) / \ - sp.ICMPv6NDOptPrefixInfo(prefix=args.prefix, prefixlen=args.prefixlen) + sp.IPv6(src=args.src, dst=args.dst) / \ + sp.ICMPv6ND_RA(chlim=64) / \ + sp.ICMPv6NDOptPrefixInfo(prefix=args.prefix, prefixlen=args.prefixlen) sp.sendp(pkt, iface=args.sendif[0], verbose=False) sys.exit(0) + if __name__ == '__main__': main()help
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?69455d80.3c918.383f8f8a>
