mirror of
https://github.com/holub/mame
synced 2025-05-23 06:08:48 +03:00
Only enable watchdog for sdlmame if "-str" set and smaller than 300 seconds. No whatsnew.
This commit is contained in:
parent
fdb2347151
commit
e7b559190f
@ -624,7 +624,10 @@ void sdl_osd_interface::init(running_machine &machine)
|
|||||||
/* now setup watchdog */
|
/* now setup watchdog */
|
||||||
|
|
||||||
int watchdog_timeout = options_get_int(machine.options(), SDLOPTION_WATCHDOG);
|
int watchdog_timeout = options_get_int(machine.options(), SDLOPTION_WATCHDOG);
|
||||||
if (watchdog_timeout != 0)
|
int str = options_get_int(machine.options(), OPTION_SECONDS_TO_RUN);
|
||||||
|
|
||||||
|
/* only enable watchdog if seconds_to_run is enabled *and* relatively short (time taken from ui.c) */
|
||||||
|
if ((watchdog_timeout != 0) && (str > 0) && (str < 60*5 ))
|
||||||
{
|
{
|
||||||
m_watchdog = auto_alloc(&machine, watchdog);
|
m_watchdog = auto_alloc(&machine, watchdog);
|
||||||
m_watchdog->setTimeout(watchdog_timeout);
|
m_watchdog->setTimeout(watchdog_timeout);
|
||||||
|
Loading…
Reference in New Issue
Block a user