mirror of
https://github.com/xen-project/xen.git
synced 2026-10-28 02:01:24 +01:00
libxc: only munmap when something has actually been mapped in change_pte
Coverity-ID: 1055269 signed-off-by: Matthew Daley <mattjd@gmail.com> Acked-by: Ian Campbell <ian.campbell@citrix.com>
This commit is contained in:
1 parent
c8f5eb4b80
commit
c827d7f39f
1 file changed
+3
-3
@@ -317,10 +317,10 @@ static int change_pte(xc_interface *xch, int domid,
|
||||
goto failed;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
munmap(content, PAGE_SIZE);
|
||||
content = NULL;
|
||||
munmap(content, PAGE_SIZE);
|
||||
content = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
if ( xc_flush_mmu_updates(xch, mmu) )
|
||||
|
||||