Page MenuHomeFreeBSD

D40721.diff
No OneTemporary

D40721.diff

diff --git a/sys/kern/subr_pctrie.c b/sys/kern/subr_pctrie.c
--- a/sys/kern/subr_pctrie.c
+++ b/sys/kern/subr_pctrie.c
@@ -749,7 +749,7 @@
if (tmp != NULL)
break;
}
- KASSERT(i != PCTRIE_COUNT,
+ KASSERT(tmp != NULL,
("%s: invalid node configuration", __func__));
if (parent == NULL)
pctrie_root_store(ptree, tmp, PCTRIE_LOCKED);
diff --git a/sys/vm/vm_radix.c b/sys/vm/vm_radix.c
--- a/sys/vm/vm_radix.c
+++ b/sys/vm/vm_radix.c
@@ -773,13 +773,14 @@
rnode->rn_count--;
if (rnode->rn_count > 1)
return (m);
- for (i = 0; i < VM_RADIX_COUNT; i++)
- if (vm_radix_node_load(&rnode->rn_child[i],
- LOCKED) != NULL)
+ for (i = 0; i < VM_RADIX_COUNT; i++) {
+ tmp = vm_radix_node_load(&rnode->rn_child[i],
+ LOCKED);
+ if (tmp != NULL)
break;
- KASSERT(i != VM_RADIX_COUNT,
+ }
+ KASSERT(tmp != NULL,
("%s: invalid node configuration", __func__));
- tmp = vm_radix_node_load(&rnode->rn_child[i], LOCKED);
if (parent == NULL)
vm_radix_root_store(rtree, tmp, LOCKED);
else {

File Metadata

Mime Type
text/plain
Expires
Sat, Nov 16, 9:25 PM (21 h, 57 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
14664585
Default Alt Text
D40721.diff (1 KB)

Event Timeline