cocos2d / cocos2d-x

Cocos2d-x is a suite of open-source, cross-platform, game-development tools utilized by millions of developers across the globe. Its core has evolved to serve as the foundation for Cocos Creator 1.x & 2.x.
https://www.cocos.com/en/cocos2d-x
18.16k stars 7.05k forks source link

Fix memory leak on Texture2DGL::getBytes() #20728

Open papatr0x opened 2 years ago

papatr0x commented 2 years ago

When using Texture2DGL::getBytes() on flipped images, only memory for flipped image is being released and original image memory is not. This pull fix this issue freeing original image in all cases.

papatr0x commented 2 years ago

appveyor failed for android and windows due to python issues, not due to this change.