mirror of
https://github.com/libsdl-org/SDL.git
synced 2026-01-04 04:22:41 +00:00
video: fix surface leak when duplicating mjpeg
This commit is contained in:
@@ -1948,6 +1948,7 @@ SDL_Surface *SDL_ConvertSurfaceAndColorspace(SDL_Surface *surface, SDL_PixelForm
|
||||
if (!convert->pixels) {
|
||||
goto error;
|
||||
}
|
||||
convert->flags &= ~SDL_SURFACE_PREALLOCATED;
|
||||
convert->pitch = surface->pitch;
|
||||
SDL_memcpy(convert->pixels, surface->pixels, size);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user