Commit 82c94a3f795150dfa16122232554719032b63cae

Philipp Wiesemann 2016-08-03T22:32:20

PSP: Fixed memory leak if video init failed.

1
2
3
4
5
6
7
8
9
10
11
12
diff --git a/src/video/psp/SDL_pspvideo.c b/src/video/psp/SDL_pspvideo.c
index d43c760..381e489 100644
--- a/src/video/psp/SDL_pspvideo.c
+++ b/src/video/psp/SDL_pspvideo.c
@@ -92,6 +92,7 @@ PSP_Create()
     if (gldata == NULL) {
         SDL_OutOfMemory();
         SDL_free(device);
+        SDL_free(phdata);
         return NULL;
     }
     device->gl_data = gldata;