mirror of https://github.com/libsdl-org/SDL.git
video: fix surface leak when duplicating mjpeg
This commit is contained in:
parent
567dfd2ebc
commit
eb918af3dc
|
|
@ -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);
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue