aboutsummaryrefslogtreecommitdiff
path: root/rumpdisk/block-rump.c
diff options
context:
space:
mode:
Diffstat (limited to 'rumpdisk/block-rump.c')
-rw-r--r--rumpdisk/block-rump.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/rumpdisk/block-rump.c b/rumpdisk/block-rump.c
index 309495dd..01dfd389 100644
--- a/rumpdisk/block-rump.c
+++ b/rumpdisk/block-rump.c
@@ -376,6 +376,7 @@ rumpdisk_device_write (void *d, mach_port_t reply_port,
if (written < 0)
{
+ vm_deallocate (mach_task_self (), (vm_address_t) data, count);
pthread_rwlock_unlock (&rumpdisk_rwlock);
return rump_errno2host (err);
}
@@ -405,6 +406,7 @@ rumpdisk_device_write (void *d, mach_port_t reply_port,
if (done < 0)
{
+ vm_deallocate (mach_task_self (), (vm_address_t) data, count);
pthread_rwlock_unlock (&rumpdisk_rwlock);
return rump_errno2host (errno);
}