Return at least 64MB VRAM in case the detection fails

This commit is contained in:
dhewg 2012-01-08 11:41:25 +01:00
parent a35d8c08b6
commit 5f8712902c

View file

@ -276,7 +276,10 @@ int Sys_GetVideoRam() {
common->Printf("guessing video ram (use +set sys_videoRam to force)\n");
const SDL_VideoInfo *vi = SDL_GetVideoInfo();
Uint32 vram = SDL_GetVideoInfo()->video_mem;
return vi->video_mem;
if (!vram)
vram = 64;
return vram;
}