aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Tuexen <tuexen@FreeBSD.org>2025-09-10 19:46:24 +0000
committerMichael Tuexen <tuexen@FreeBSD.org>2025-09-10 19:46:24 +0000
commitc3d5387a7bd814a6c341902c29a3f8aaa956fadb (patch)
treef512e6ebd00d08a4a7b40408452d0fa6f15fb19a
parenta8a18eeb5e1711ad27c3ee20eb342b73d3badffa (diff)
tcp: minor cleanup
No functional change intended. MFC after: 3 days Sponsored by: Netflix, Inc.
-rw-r--r--sys/netinet/tcp_subr.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/netinet/tcp_subr.c b/sys/netinet/tcp_subr.c
index 2e039ebbfdd2..cc83a21773a8 100644
--- a/sys/netinet/tcp_subr.c
+++ b/sys/netinet/tcp_subr.c
@@ -645,14 +645,14 @@ out:
static int
sysctl_net_inet_default_tcp_functions(SYSCTL_HANDLER_ARGS)
{
- int error = ENOENT;
struct tcp_function_set fs;
struct tcp_function_block *blk;
+ int error;
- memset(&fs, 0, sizeof(fs));
+ memset(&fs, 0, sizeof(struct tcp_function_set));
rw_rlock(&tcp_function_lock);
blk = find_tcp_fb_locked(V_tcp_func_set_ptr, NULL);
- if (blk) {
+ if (blk != NULL) {
/* Found him */
strcpy(fs.function_set_name, blk->tfb_tcp_block_name);
fs.pcbcnt = blk->tfb_refcnt;