Handle zero length in copyout_unmap().
Submitted by: John Wehle <john feith com> MFC after: 2 weeks
This commit is contained in:
parent
0f502d1c4e
commit
937060a843
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=220101
@ -498,6 +498,9 @@ copyout_unmap(struct thread *td, vm_offset_t addr, size_t sz)
|
||||
vm_map_t map;
|
||||
vm_size_t size;
|
||||
|
||||
if (sz == 0)
|
||||
return (0);
|
||||
|
||||
map = &td->td_proc->p_vmspace->vm_map;
|
||||
size = (vm_size_t) round_page(sz);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user