Date: Wed, 23 Oct 2024 07:24:33 GMT From: Baptiste Daroussin <bapt@FreeBSD.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org Subject: git: 8610fcedb98b - stable/14 - genl: small cleanup Message-ID: <202410230724.49N7OXBH036483@gitrepo.freebsd.org>
next in thread | raw e-mail | index | archive | help
The branch stable/14 has been updated by bapt: URL: https://cgit.FreeBSD.org/src/commit/?id=8610fcedb98bf6960c1bfd80084125016e1f8709 commit 8610fcedb98bf6960c1bfd80084125016e1f8709 Author: Baptiste Daroussin <bapt@FreeBSD.org> AuthorDate: 2024-10-07 13:28:54 +0000 Commit: Baptiste Daroussin <bapt@FreeBSD.org> CommitDate: 2024-10-23 07:24:09 +0000 genl: small cleanup Following up from another review using basically the same code: remove useless cast replace uint32_t with unsigned int. No functional changes expected (cherry picked from commit 782766a32d963587a6aac8521aedd132b68a9dab) --- usr.bin/genl/genl.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/usr.bin/genl/genl.c b/usr.bin/genl/genl.c index 48c74fa20c81..df2758c273f3 100644 --- a/usr.bin/genl/genl.c +++ b/usr.bin/genl/genl.c @@ -247,13 +247,13 @@ monitor_mcast(int argc __unused, char **argv) errx(EXIT_FAILURE, "Unknown family '%s'", argv[0]); if (argc == 1) all = true; - for (uint32_t i = 0; i < attrs.mcast_groups.num_groups; i++) { + for (unsigned int i = 0; i < attrs.mcast_groups.num_groups; i++) { if (all || strcmp(attrs.mcast_groups.groups[i]->mcast_grp_name, argv[1]) == 0) { found = true; if (setsockopt(ss.fd, SOL_NETLINK, NETLINK_ADD_MEMBERSHIP, - (void *)&attrs.mcast_groups.groups[i]->mcast_grp_id, + &attrs.mcast_groups.groups[i]->mcast_grp_id, sizeof(attrs.mcast_groups.groups[i]->mcast_grp_id)) == -1) err(EXIT_FAILURE, "Cannot subscribe to command "
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202410230724.49N7OXBH036483>