summaryrefslogtreecommitdiffstats
path: root/sys/kern/subr_uio.c
diff options
context:
space:
mode:
Diffstat (limited to 'sys/kern/subr_uio.c')
-rw-r--r--sys/kern/subr_uio.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/sys/kern/subr_uio.c b/sys/kern/subr_uio.c
index 8304aea..d8fa68f 100644
--- a/sys/kern/subr_uio.c
+++ b/sys/kern/subr_uio.c
@@ -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);
OpenPOWER on IntegriCloud