Page MenuHomeFreeBSD

D19183.diff
No OneTemporary

D19183.diff

diff --git a/lib/libkvm/kvm_private.c b/lib/libkvm/kvm_private.c
--- a/lib/libkvm/kvm_private.c
+++ b/lib/libkvm/kvm_private.c
@@ -792,8 +792,8 @@
/* Find the next valid idx. */
for (; *idx < first_invalid; (*idx)++) {
- unsigned int mask = *idx % CHAR_BIT;
- if ((bm->map[*idx * CHAR_BIT] & mask) == 0)
+ unsigned int mask = 1U << (*idx % CHAR_BIT);
+ if ((bm->map[*idx / CHAR_BIT] & mask) != 0)
break;
}

File Metadata

Mime Type
text/plain
Expires
Fri, Jan 31, 11:04 AM (14 h, 43 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
16361428
Default Alt Text
D19183.diff (425 B)

Event Timeline