mirror of
https://github.com/hrydgard/ppsspp.git
synced 2025-04-02 11:01:50 -04:00
Merge pull request #5247 from unknownbrackets/callbacks
Work around a callback issue and a strange debug-only crash
This commit is contained in:
commit
1268bbd489
2 changed files with 7 additions and 0 deletions
|
@ -2299,6 +2299,8 @@ void sceKernelExitDeleteThread(int exitStatus)
|
|||
{
|
||||
INFO_LOG(SCEKERNEL,"sceKernelExitDeleteThread(%d)", exitStatus);
|
||||
__KernelDeleteThread(currentThread, exitStatus, "thread exited with delete");
|
||||
// Temporary hack since we don't reschedule within callbacks.
|
||||
g_inCbCount = 0;
|
||||
|
||||
hleReSchedule("thread exited with delete");
|
||||
}
|
||||
|
|
|
@ -588,7 +588,12 @@ int ZEXPORT gzclose_r(file)
|
|||
err = state->err == Z_BUF_ERROR ? Z_BUF_ERROR : Z_OK;
|
||||
gz_error(state, Z_OK, NULL);
|
||||
free(state->path);
|
||||
#ifdef _WIN32
|
||||
// Strange crash in debug-only when using close() under MSVC 2010.
|
||||
ret = _close(state->fd);
|
||||
#else
|
||||
ret = close(state->fd);
|
||||
#endif
|
||||
free(state);
|
||||
return ret ? Z_ERRNO : err;
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue