Index: src/gpu/vk/GrVkImage.cpp |
diff --git a/src/gpu/vk/GrVkImage.cpp b/src/gpu/vk/GrVkImage.cpp |
index 70dd4486ae3dee89c1eb057d6ae4d8498cfb4875..11e27ed66404575200852c7603887bdfff224f6c 100644 |
--- a/src/gpu/vk/GrVkImage.cpp |
+++ b/src/gpu/vk/GrVkImage.cpp |
@@ -61,6 +61,9 @@ void GrVkImage::setImageLayout(const GrVkGpu* gpu, VkImageLayout newLayout, |
} |
bool GrVkImage::InitImageInfo(const GrVkGpu* gpu, const ImageDesc& imageDesc, GrVkImageInfo* info) { |
+ if (0 == imageDesc.fWidth || 0 == imageDesc.fHeight) { |
+ return false; |
+ } |
VkImage image = 0; |
GrVkAlloc alloc; |