git: d46d45bf4b19 - main - tools/fib_multibind: Remove a redundant calculation
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Fri, 14 Feb 2025 15:24:22 UTC
The branch main has been updated by markj:
URL: https://cgit.FreeBSD.org/src/commit/?id=d46d45bf4b196cd2daba42d5413f8e4d7ffedeed
commit d46d45bf4b196cd2daba42d5413f8e4d7ffedeed
Author: Mark Johnston <markj@FreeBSD.org>
AuthorDate: 2025-02-14 15:16:52 +0000
Commit: Mark Johnston <markj@FreeBSD.org>
CommitDate: 2025-02-14 15:24:15 +0000
tools/fib_multibind: Remove a redundant calculation
No functional change intended.
Reported by: kevans
Fixes: 3fa552149885 ("tools: Add a small program to demonstrate FIB handling in bind(2)")
Sponsored by: Klara, Inc.
Sponsored by: Stormshield
---
tools/tools/fib_multibind/sink.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tools/tools/fib_multibind/sink.c b/tools/tools/fib_multibind/sink.c
index fe93a66fe266..8f8c31f0c8ea 100644
--- a/tools/tools/fib_multibind/sink.c
+++ b/tools/tools/fib_multibind/sink.c
@@ -158,7 +158,7 @@ main(int argc, char **argv)
sc.nfibs = 1;
}
- sc.fds = calloc(all ? sc.nfibs : 1, sizeof(int));
+ sc.fds = calloc(sc.nfibs, sizeof(int));
if (sc.fds == NULL)
err(1, "calloc");
for (int i = 0; i < sc.nfibs; i++) {