made check for empty SDL_MODE environment variable more robust