diff options
author | Campbell Barton <ideasman42@gmail.com> | 2021-09-06 13:32:35 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2021-09-06 13:32:35 +0300 |
commit | 4f0ec3cea5732e5b06122519538488e104c7ff00 (patch) | |
tree | 17e02745baa9f55a91b2c6b3bda851a1e554fd83 /source/blender | |
parent | 687f70ceca88324fb8f376e086a55b341dd34e6f (diff) |
Cleanup: use pre-calculated size variable
Oversight in a0912ff5663b950222ef00485a3853bfb6001db4
Diffstat (limited to 'source/blender')
-rw-r--r-- | source/blender/imbuf/intern/allocimbuf.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/imbuf/intern/allocimbuf.c b/source/blender/imbuf/intern/allocimbuf.c index c2bff9ddc51..1369f8cc0f8 100644 --- a/source/blender/imbuf/intern/allocimbuf.c +++ b/source/blender/imbuf/intern/allocimbuf.c @@ -484,7 +484,7 @@ struct ImBuf *IMB_allocFromBuffer(const unsigned int *rect, /* Avoid #MEM_dupallocN since the buffers might not be allocated using guarded-allocation. */ if (rectf) { const size_t size = sizeof(float[4]) * w * h; - ibuf->rect_float = MEM_mallocN(sizeof(float[4]) * w * h, __func__); + ibuf->rect_float = MEM_mallocN(size, __func__); memcpy(ibuf->rect_float, rectf, size); ibuf->flags |= IB_rectfloat; |