Only run dead thread check on complete emulation
This commit is contained in:
parent
899b82c36f
commit
722e32617a
@ -127,8 +127,10 @@ emu_step(struct emu *emu)
|
||||
int ret = player_step(&emu->player);
|
||||
|
||||
/* No more events */
|
||||
if (ret > 0)
|
||||
if (ret > 0) {
|
||||
emu->finished = 1;
|
||||
return +1;
|
||||
}
|
||||
|
||||
/* Error happened */
|
||||
if (ret < 0) {
|
||||
|
@ -30,6 +30,8 @@ struct emu {
|
||||
struct recorder recorder;
|
||||
struct emu_stat stat;
|
||||
|
||||
int finished;
|
||||
|
||||
/* Quick access */
|
||||
struct stream *stream;
|
||||
struct emu_ev *ev;
|
||||
|
@ -6,6 +6,10 @@
|
||||
int
|
||||
ovni_finish(struct emu *emu)
|
||||
{
|
||||
/* Skip the check if the we are stopping prematurely */
|
||||
if (!emu->finished)
|
||||
return 0;
|
||||
|
||||
struct system *sys = &emu->system;
|
||||
int ret = 0;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user