loader: gh971 Fix double free on physical devices
authorMaciej Jesionowski <maciej.jesionowski@mobica.com>
Fri, 30 Sep 2016 13:14:52 +0000 (15:14 +0200)
committerMark Young <marky@lunarg.com>
Fri, 30 Sep 2016 22:53:49 +0000 (16:53 -0600)
Change-Id: I97428dd579217340586809577eb64277ed4bb2cd

loader/loader.c

index 2400ae3..1c6591f 100644 (file)
@@ -4457,6 +4457,7 @@ terminator_EnumeratePhysicalDevices(VkInstance instance,
 
         if (inst->phys_devs_term) {
             loader_instance_heap_free(inst, inst->phys_devs_term);
+            inst->phys_devs_term = NULL;
         }
 
         if (copy_count > 0) {