On 10.1, parse_screen_prefs() was being called with a nil string

(i.e. PrefsInit wasn't getting a screen pref item). Cope with that.
This commit is contained in:
nigel 2004-01-27 04:39:33 +00:00
parent db3c11dd75
commit 4a61b727af

View File

@ -101,6 +101,9 @@ colours_from_depth(const uint16 depth)
bool
parse_screen_prefs(const char *mode_str)
{
if ( ! mode_str )
return false;
if (sscanf(mode_str, "win/%hd/%hd/%hd",
&init_width, &init_height, &init_depth) == 3)
display_type = DISPLAY_WINDOW;