layers: Remove redundant code
authorJeremy Hayes <jeremy@lunarg.com>
Tue, 13 Dec 2016 20:09:44 +0000 (13:09 -0700)
committerJeremy Hayes <jeremy-lunarg@users.noreply.github.com>
Mon, 9 Jan 2017 23:36:44 +0000 (16:36 -0700)
This is already being checked in the object tracker layer.

Change-Id: Ie1d5776810c3f8a3df7b9ef920d02e90c0d239b4

layers/core_validation.cpp

index c92171b9bd0ecb3433219698767c27d0f07f318c..9d29f0d897d01762a31b33b0e32e5d9afad8c969 100644 (file)
@@ -768,10 +768,7 @@ static bool SetMemBinding(layer_data *dev_data, VkDeviceMemory mem, uint64_t han
                           const char *apiName) {
     bool skip_call = false;
     // It's an error to bind an object to NULL memory
-    if (mem == VK_NULL_HANDLE) {
-        skip_call = log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, type, handle, __LINE__, MEMTRACK_INVALID_MEM_OBJ,
-                            "MEM", "In %s, attempting to Bind Obj(0x%" PRIxLEAST64 ") to NULL", apiName, handle);
-    } else {
+    if (mem != VK_NULL_HANDLE) {
         BINDABLE *mem_binding = GetObjectMemBinding(dev_data, handle, type);
         assert(mem_binding);
         // TODO : Add check here to make sure object isn't sparse