aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Pinedo <david@lunarg.com>2015-07-31 10:46:25 -0600
committerCourtney Goeltzenleuchter <courtney@LunarG.com>2015-07-31 14:15:23 -0600
commitf55baee01d192eeac34b6bec4b50ea605d326372 (patch)
tree69cffd8f4f12c7dcbd792abe251c651f1a49e5b2
parent430b435a9b6e2c17f38e518281040ef53f5ea3f1 (diff)
downloadusermoji-f55baee01d192eeac34b6bec4b50ea605d326372.tar.xz
ObjectTracker Layer: Fix crash on windows in CreateInstance
function explicit_CreateInstance was crashing when it tried to use a mutex before it was initialized. Determined mutex wasn't needed at the start of this function, so remove the lock.
-rw-r--r--layers/object_track.h3
1 files changed, 1 insertions, 2 deletions
diff --git a/layers/object_track.h b/layers/object_track.h
index 824c255b..ac9c6c1b 100644
--- a/layers/object_track.h
+++ b/layers/object_track.h
@@ -440,7 +440,7 @@ explicit_CreateInstance(
const VkInstanceCreateInfo *pCreateInfo,
VkInstance * pInstance)
{
- loader_platform_thread_lock_mutex(&objLock);
+
VkLayerInstanceDispatchTable *pInstanceTable = get_dispatch_table(ObjectTracker_instance_table_map, *pInstance);
VkResult result = pInstanceTable->CreateInstance(pCreateInfo, pInstance);
@@ -455,7 +455,6 @@ explicit_CreateInstance(
initObjectTracker(my_data);
create_obj(*pInstance, *pInstance, VK_OBJECT_TYPE_INSTANCE);
}
- loader_platform_thread_unlock_mutex(&objLock);
return result;
}