mirror of
https://github.com/ZDoom/gzdoom-gles.git
synced 2024-11-11 07:12:16 +00:00
Merge pull request #19 from edward-san/unix_no_gtk_iwadpicker_fix
- Fixed scanf in IWAD picker without GTK
This commit is contained in:
commit
3111f8f93d
1 changed files with 1 additions and 2 deletions
|
@ -684,8 +684,7 @@ int I_PickIWad (WadStuff *wads, int numwads, bool showwin, int defaultiwad)
|
|||
printf ("%d. %s (%s)\n", i+1, wads[i].Name.GetChars(), filepart);
|
||||
}
|
||||
printf ("Which one? ");
|
||||
scanf ("%d", &i);
|
||||
if (i > numwads)
|
||||
if (scanf ("%d", &i) != 1 || i > numwads)
|
||||
return -1;
|
||||
return i-1;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue