mirror of https://github.com/mgba-emu/mgba.git
Core: Suspend runloop when a core crashes
This commit is contained in:
parent
29115e711b
commit
2a316ee1dc
1
CHANGES
1
CHANGES
|
@ -12,6 +12,7 @@ Other fixes:
|
|||
- Qt: Fix applying savetype-only overrides
|
||||
- Util: Fix loading UPS patches that affect the last byte of the file
|
||||
Misc:
|
||||
- Core: Suspend runloop when a core crashes
|
||||
- Qt: Rearrange menus some
|
||||
- Util: Improve speed of UPS patch loading
|
||||
|
||||
|
|
|
@ -55,13 +55,13 @@ enum mCoreThreadState {
|
|||
mTHREAD_INTERRUPTED,
|
||||
mTHREAD_PAUSED,
|
||||
mTHREAD_MIN_WAITING = mTHREAD_INTERRUPTED,
|
||||
mTHREAD_CRASHED,
|
||||
mTHREAD_MAX_WAITING = mTHREAD_PAUSED,
|
||||
|
||||
mTHREAD_INTERRUPTING,
|
||||
mTHREAD_EXITING,
|
||||
|
||||
mTHREAD_SHUTDOWN,
|
||||
mTHREAD_CRASHED
|
||||
mTHREAD_SHUTDOWN
|
||||
};
|
||||
|
||||
enum mCoreThreadRequest {
|
||||
|
|
|
@ -189,6 +189,7 @@ CoreController::CoreController(mCore* core, QObject* parent)
|
|||
message = QString().vsprintf(format, args);
|
||||
QMetaObject::invokeMethod(controller, "logPosted", Q_ARG(int, level), Q_ARG(int, category), Q_ARG(const QString&, message));
|
||||
if (level == mLOG_FATAL) {
|
||||
mCoreThreadMarkCrashed(controller->thread());
|
||||
QMetaObject::invokeMethod(controller, "crashed", Q_ARG(const QString&, QString().vsprintf(format, args)));
|
||||
}
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue