Error checking for sdl init