summaryrefslogtreecommitdiffstats
path: root/usr.sbin
diff options
context:
space:
mode:
authordv <dv@openbsd.org>2021-04-01 11:05:47 +0000
committerdv <dv@openbsd.org>2021-04-01 11:05:47 +0000
commite06d60ddcb6cd50b09e2ab3bfb10971d9db7deda (patch)
tree6392e54fb1aa70614c20751008a627895d849902 /usr.sbin
parentAbate superfluous lines from remote servers (diff)
downloadwireguard-openbsd-e06d60ddcb6cd50b09e2ab3bfb10971d9db7deda.tar.xz
wireguard-openbsd-e06d60ddcb6cd50b09e2ab3bfb10971d9db7deda.zip
Remove extraneous call of vm_getbyvmid during pause event
The vm is already being assigned by a call in the if-condition.
Diffstat (limited to 'usr.sbin')
-rw-r--r--usr.sbin/vmd/vmm.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/usr.sbin/vmd/vmm.c b/usr.sbin/vmd/vmm.c
index faebf670dee..5238cf6a716 100644
--- a/usr.sbin/vmd/vmm.c
+++ b/usr.sbin/vmd/vmm.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: vmm.c,v 1.98 2021/03/29 23:37:01 dv Exp $ */
+/* $OpenBSD: vmm.c,v 1.99 2021/04/01 11:05:47 dv Exp $ */
/*
* Copyright (c) 2015 Mike Larkin <mlarkin@openbsd.org>
@@ -273,7 +273,6 @@ vmm_dispatch_parent(int fd, struct privsep_proc *p, struct imsg *imsg)
IMSG_SIZE_CHECK(imsg, &vid);
memcpy(&vid, imsg->data, sizeof(vid));
id = vid.vid_id;
- vm = vm_getbyvmid(id);
if ((vm = vm_getbyvmid(id)) == NULL) {
res = ENOENT;
cmd = IMSG_VMDOP_PAUSE_VM_RESPONSE;