diff src/video/nds/SDL_ndsvideo.c @ 3520:83518f8fcd61

Fixed calls to SDL_AddRenderDriver()
author Sam Lantinga <slouken@libsdl.org>
date Fri, 04 Dec 2009 08:45:08 +0000
parents 99210400e8b9
children f7b03b6838cb
line wrap: on
line diff
--- a/src/video/nds/SDL_ndsvideo.c	Fri Dec 04 08:26:32 2009 +0000
+++ b/src/video/nds/SDL_ndsvideo.c	Fri Dec 04 08:45:08 2009 +0000
@@ -110,8 +110,10 @@
     mode.refresh_rate = 60;
     mode.driverdata = NULL;
 
-    SDL_AddBasicVideoDisplay(&mode);
-    SDL_AddRenderDriver(0, &NDS_RenderDriver);
+    if (SDL_AddBasicVideoDisplay(&mode) < 0) {
+        return -1;
+    }
+    SDL_AddRenderDriver(&_this->displays[0], &NDS_RenderDriver);
 
     SDL_zero(mode);
     SDL_AddDisplayMode(0, &mode);