diff options
author | Mike Belopuhov <mikeb@cvs.openbsd.org> | 2017-01-20 16:57:39 +0000 |
---|---|---|
committer | Mike Belopuhov <mikeb@cvs.openbsd.org> | 2017-01-20 16:57:39 +0000 |
commit | 4333267cf7a1bdf104e6fcf797697549ed3693ac (patch) | |
tree | 53da8353689e2407287e4278f83401ad370b69fb /sys | |
parent | ef7b697cda8d4722e36e2a761659045107a41dac (diff) |
Merge two conditional expressions
Diffstat (limited to 'sys')
-rw-r--r-- | sys/dev/pv/xen.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/sys/dev/pv/xen.c b/sys/dev/pv/xen.c index dbc1d670a17..7721e2a37d9 100644 --- a/sys/dev/pv/xen.c +++ b/sys/dev/pv/xen.c @@ -1,4 +1,4 @@ -/* $OpenBSD: xen.c,v 1.71 2017/01/10 17:16:39 reyk Exp $ */ +/* $OpenBSD: xen.c,v 1.72 2017/01/20 16:57:38 mikeb Exp $ */ /* * Copyright (c) 2015 Mike Belopuhov @@ -1364,9 +1364,8 @@ xen_hotplug(void *arg) /* Detect all removed and kept devices */ LIST_FOREACH_SAFE(xdv, &xdl->dl_devs, dv_entry, xvdn) { for (i = 0, keep = 0; i < iov_cnt; i++) { - if (seen[i]) - continue; - if (!strcmp(xdv->dv_unit, (char *)iovp[i].iov_base)) { + if (!seen[i] && + !strcmp(xdv->dv_unit, (char *)iovp[i].iov_base)) { seen[i]++; keep++; break; |