summary refs log tree commit diff stats
path: root/xen-mapcache.c
diff options
context:
space:
mode:
Diffstat (limited to 'xen-mapcache.c')
-rw-r--r--xen-mapcache.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/xen-mapcache.c b/xen-mapcache.c
index 8cefd0c62f..97fece2358 100644
--- a/xen-mapcache.c
+++ b/xen-mapcache.c
@@ -169,10 +169,8 @@ static void xen_remap_bucket(MapCacheEntry *entry,
             exit(-1);
         }
     }
-    if (entry->valid_mapping != NULL) {
-        g_free(entry->valid_mapping);
-        entry->valid_mapping = NULL;
-    }
+    g_free(entry->valid_mapping);
+    entry->valid_mapping = NULL;
 
     for (i = 0; i < nb_pfn; i++) {
         pfns[i] = (address_index << (MCACHE_BUCKET_SHIFT-XC_PAGE_SHIFT)) + i;