diff options
| author | ptitSeb <sebastien.chev@gmail.com> | 2023-10-17 17:29:32 +0200 |
|---|---|---|
| committer | ptitSeb <sebastien.chev@gmail.com> | 2023-10-17 17:29:32 +0200 |
| commit | 5493ab345ac2af9ac3a3ef0bfd321eaf3910460c (patch) | |
| tree | 43bd5139f78da43c0937c59c8ecaaf491bf5890f /src/emu | |
| parent | 2589f7db14f7739f58c2e2c9634799c629307a15 (diff) | |
| download | box64-5493ab345ac2af9ac3a3ef0bfd321eaf3910460c.tar.gz box64-5493ab345ac2af9ac3a3ef0bfd321eaf3910460c.zip | |
Some more rollback on tls destructor (more work needed on threads cleanup handling)
Diffstat (limited to 'src/emu')
| -rw-r--r-- | src/emu/x64int3.c | 6 | ||||
| -rw-r--r-- | src/emu/x64run.c | 4 |
2 files changed, 5 insertions, 5 deletions
diff --git a/src/emu/x64int3.c b/src/emu/x64int3.c index c602f61b..9f858fb0 100644 --- a/src/emu/x64int3.c +++ b/src/emu/x64int3.c @@ -40,7 +40,7 @@ x64emu_t* x64emu_fork(x64emu_t* emu, int forktype) for (int i=my_context->atfork_sz-1; i>=0; --i) if(my_context->atforks[i].prepare) EmuCall(emu, my_context->atforks[i].prepare); - int type = emu->type; + //int type = emu->type; int v; if(forktype==2) { iFpppp_t forkpty = (iFpppp_t)emu->forkpty_info->f; @@ -48,8 +48,8 @@ x64emu_t* x64emu_fork(x64emu_t* emu, int forktype) emu->forkpty_info = NULL; } else v = fork(); - if(type == EMUTYPE_MAIN) - thread_set_emu(emu); + /*if(type == EMUTYPE_MAIN) + thread_set_emu(emu);*/ if(v==EAGAIN || v==ENOMEM) { // error... } else if(v!=0) { diff --git a/src/emu/x64run.c b/src/emu/x64run.c index 7be78a21..f9f6e14e 100644 --- a/src/emu/x64run.c +++ b/src/emu/x64run.c @@ -2047,12 +2047,12 @@ if(emu->segs[_CS]!=0x33 && emu->segs[_CS]!=0x23) printf_log(LOG_NONE, "Warning, // fork handling if(emu->fork) { addr = R_RIP; - if(step) - return 0; int forktype = emu->fork; emu->quit = 0; emu->fork = 0; emu = x64emu_fork(emu, forktype); + if(step) + return 0; goto x64emurun; } // setcontext handling |