aboutsummaryrefslogtreecommitdiff
path: root/exec.c
diff options
context:
space:
mode:
Diffstat (limited to 'exec.c')
-rw-r--r--exec.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/exec.c b/exec.c
index 8f5e7abfa7..26681ce021 100644
--- a/exec.c
+++ b/exec.c
@@ -1230,9 +1230,11 @@ void qemu_ram_free(ram_addr_t addr)
;
} else if (xen_enabled()) {
xen_invalidate_map_cache_entry(block->host);
+#ifndef _WIN32
} else if (block->fd >= 0) {
munmap(block->host, block->length);
close(block->fd);
+#endif
} else {
qemu_anon_ram_free(block->host, block->length);
}