summaryrefslogtreecommitdiffstats
path: root/lib/libc/stdlib/merge.c
diff options
context:
space:
mode:
authorkettenis <kettenis@openbsd.org>2015-06-20 20:20:08 +0000
committerkettenis <kettenis@openbsd.org>2015-06-20 20:20:08 +0000
commit6fd881a3a635cbb4ce871f16c121a186a814fc18 (patch)
tree5dc772dbc9459ef12f80e841849c88226bed7892 /lib/libc/stdlib/merge.c
parentConvert ssl3_get_new_session_ticket to CBS. (diff)
downloadwireguard-openbsd-6fd881a3a635cbb4ce871f16c121a186a814fc18.tar.xz
wireguard-openbsd-6fd881a3a635cbb4ce871f16c121a186a814fc18.zip
Fix a bug that causes uvm_pmr_get1page() to fail for allocations that
specify an address constraint even when free pages that meet the constraint are still available. This happens because the old code was using the root of the size tree as a starting point for a search down the address tree. This meant only part of the address tree was searched, and that part could very well not contain any of the pages that met the constraint. Instead, always walk the address tree from its root if the list of single pages is empty and the root of the size tree doesn't meet our constraints. From Visa Hankala. ok deraadt@
Diffstat (limited to 'lib/libc/stdlib/merge.c')
0 files changed, 0 insertions, 0 deletions