diff options
| author | 2017-01-31 05:53:08 +0000 | |
|---|---|---|
| committer | 2017-01-31 05:53:08 +0000 | |
| commit | 18fc3beaedf6b8268fc9c41ac5a94458ef5b0e4f (patch) | |
| tree | 3238c2203b47f2e538c4289168e6daf815e4a182 | |
| parent | Document functions returning standard moduli for DH key exchange. (diff) | |
| download | wireguard-openbsd-18fc3beaedf6b8268fc9c41ac5a94458ef5b0e4f.tar.xz wireguard-openbsd-18fc3beaedf6b8268fc9c41ac5a94458ef5b0e4f.zip | |
Use the sizeof operator on a struct not a pointer to one.
ok rzalamena@
| -rw-r--r-- | usr.sbin/switchctl/switchctl.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.sbin/switchctl/switchctl.c b/usr.sbin/switchctl/switchctl.c index 144ae131ea6..2d57e47300c 100644 --- a/usr.sbin/switchctl/switchctl.c +++ b/usr.sbin/switchctl/switchctl.c @@ -1,4 +1,4 @@ -/* $OpenBSD: switchctl.c,v 1.6 2016/11/24 09:23:11 reyk Exp $ */ +/* $OpenBSD: switchctl.c,v 1.7 2017/01/31 05:53:08 jsg Exp $ */ /* * Copyright (c) 2007-2015 Reyk Floeter <reyk@openbsd.org> @@ -227,7 +227,7 @@ main(int argc, char *argv[]) } to = &swc.swc_target; - memcpy(&to, &res->uri, sizeof(to)); + memcpy(to, &res->uri, sizeof(*to)); imsg_compose(ibuf, IMSG_CTL_CONNECT, 0, 0, -1, &swc, sizeof(swc)); |
