Haiku: Fixed memory leak if creating framebuffer failed.
authorPhilipp Wiesemann <philipp.wiesemann@arcor.de>
Sun, 22 Jan 2017 22:15:36 +0100
changeset 1082979e882826ed4
parent 10828 2160677a2f0f
child 10830 92013fad89d1
Haiku: Fixed memory leak if creating framebuffer failed.
src/video/haiku/SDL_bframebuffer.cc
     1.1 --- a/src/video/haiku/SDL_bframebuffer.cc	Sun Jan 22 22:15:24 2017 +0100
     1.2 +++ b/src/video/haiku/SDL_bframebuffer.cc	Sun Jan 22 22:15:36 2017 +0100
     1.3 @@ -76,6 +76,7 @@
     1.4  			true);	/* Contiguous memory required */
     1.5  			
     1.6  	if(bitmap->InitCheck() != B_OK) {
     1.7 +		delete bitmap;
     1.8  		return SDL_SetError("Could not initialize back buffer!\n");
     1.9  	}
    1.10