It's smart enough to check if the buffer is big enough, but
neglected to cast to a 64 bit value so it overflowed.
note that casting to size_t seems the obvious solution here
but that would not fix the overflow for 32 bit architectures.
Differential D15457
Fix T99705: fix integer overflow in thumbnail extractor Authored by Ray Molenkamp (LazyDodo) on Jul 14 2022, 6:54 PM. Tags None Subscribers None
Details It's smart enough to check if the buffer is big enough, but note that casting to size_t seems the obvious solution here
Diff Detail
Event TimelineComment Actions https://builder.blender.org/admin/#/builders/18/builds/536 doing a quick buildbot run just to make sure i didn't add any warns on linux/mac Comment Actions If width and height are at their maximum value, multiplying by 4 can still make it overflow. |