mirror of
https://github.com/Oibaf66/uae-wii.git
synced 2024-11-25 12:06:55 +01:00
Handle when no disk is inserted, fix memory leak
This commit is contained in:
parent
6dbbf85bf6
commit
be0c9d333f
@ -172,7 +172,15 @@ static void insert_floppy(int which)
|
||||
const char *name = menu_select_file(prefs_get_attr("floppy_path"));
|
||||
|
||||
if (name != NULL)
|
||||
{
|
||||
if (strcmp(name, "None") == 0)
|
||||
changed_prefs.df[which][0] = '\0';
|
||||
else
|
||||
strcpy (changed_prefs.df[which], name);
|
||||
free(name);
|
||||
}
|
||||
else
|
||||
changed_prefs.df[which][0] = '\0';
|
||||
}
|
||||
|
||||
static void memory_options(void)
|
||||
|
Loading…
Reference in New Issue
Block a user