diff options
author | Ted Unangst <tedu@cvs.openbsd.org> | 2016-10-08 21:27:33 +0000 |
---|---|---|
committer | Ted Unangst <tedu@cvs.openbsd.org> | 2016-10-08 21:27:33 +0000 |
commit | 9fd2aead51c06857c0ac5dcaf25a2a2dfaba7d07 (patch) | |
tree | 1b5a7bb670df79c3277522ac7f8e9b6ce27bda6d /sys/kern | |
parent | 8bc8e06f1a20d7b769734b8c49b5b8baf044ec78 (diff) |
initialize the port variable before sysctl, since it's also read out.
Diffstat (limited to 'sys/kern')
-rw-r--r-- | sys/kern/kern_sysctl.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/kern/kern_sysctl.c b/sys/kern/kern_sysctl.c index e0b8dd94cb1..bd143c91202 100644 --- a/sys/kern/kern_sysctl.c +++ b/sys/kern/kern_sysctl.c @@ -1,4 +1,4 @@ -/* $OpenBSD: kern_sysctl.c,v 1.314 2016/10/07 19:04:44 tedu Exp $ */ +/* $OpenBSD: kern_sysctl.c,v 1.315 2016/10/08 21:27:32 tedu Exp $ */ /* $NetBSD: kern_sysctl.c,v 1.17 1996/05/20 17:49:05 mrg Exp $ */ /*- @@ -608,7 +608,7 @@ kern_sysctl(int *name, u_int namelen, void *oldp, size_t *oldlenp, void *newp, #endif case KERN_DNSJACKPORT: { extern uint16_t dnsjackport; - int port; + int port = dnsjackport; if ((error = sysctl_int(oldp, oldlenp, newp, newlen, &port))) return error; if (port < 0 || port > SHRT_MAX) |