diff options
| author | Courtney Goeltzenleuchter <courtney@LunarG.com> | 2015-06-10 16:16:22 -0600 |
|---|---|---|
| committer | Courtney Goeltzenleuchter <courtney@LunarG.com> | 2015-06-10 16:18:09 -0600 |
| commit | b8640b4752ddc6b751a6447501d6f8f248503e39 (patch) | |
| tree | 7d24db798c038a096d1dee64a77324b854b46a1f | |
| parent | 8bfbd8b76a4d15ff758d49d8685d1fb7158d01fb (diff) | |
| download | usermoji-b8640b4752ddc6b751a6447501d6f8f248503e39.tar.xz | |
tri: Must destroy object before freeing it's memory
Due to spec change that makes a bound object immutable,
an object must be destroyed before any memory bound to
it is freed.
| -rw-r--r-- | demos/tri.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/demos/tri.c b/demos/tri.c index ffebfe89..1eca9b6e 100644 --- a/demos/tri.c +++ b/demos/tri.c @@ -602,8 +602,8 @@ static void demo_prepare_texture_image(struct demo *demo, static void demo_destroy_texture_image(struct demo *demo, struct texture_object *tex_obj) { /* clean up staging resources */ - vkFreeMemory(demo->device, tex_obj->mem); vkDestroyObject(demo->device, VK_OBJECT_TYPE_IMAGE, tex_obj->image); + vkFreeMemory(demo->device, tex_obj->mem); } static void demo_prepare_textures(struct demo *demo) |
