Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'source/blender/gpu/intern/gpu_draw.c')
-rw-r--r--source/blender/gpu/intern/gpu_draw.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/gpu/intern/gpu_draw.c b/source/blender/gpu/intern/gpu_draw.c
index d3d7b3b7c1d..7813ae68371 100644
--- a/source/blender/gpu/intern/gpu_draw.c
+++ b/source/blender/gpu/intern/gpu_draw.c
@@ -400,7 +400,7 @@ static void gpu_texture_update_from_ibuf(Image *ima, ImBuf *ibuf, int x, int y,
const bool store_premultiplied = (ima->alpha_mode != IMA_ALPHA_STRAIGHT);
if (ibuf->channels != 4 || scaled || !store_premultiplied) {
- rect_float = MEM_mallocN(sizeof(float) * 4 * x * y, __func__);
+ rect_float = MEM_mallocN(sizeof(float) * 4 * w * h, __func__);
if (rect_float == NULL) {
return;
}