Moving threads to XHostThread and making shutdown not crash.

This commit is contained in:
Ben Vanik
2015-05-19 22:20:49 -07:00
parent 7a82ad839a
commit f88bf33b4f
22 changed files with 175 additions and 138 deletions

View File

@@ -9,6 +9,8 @@
#include "xenia/kernel/objects/xmodule.h"
#include "xenia/base/string.h"
namespace xe {
namespace kernel {
@@ -31,6 +33,19 @@ XModule::XModule(KernelState* kernel_state, const std::string& path)
XModule::~XModule() { kernel_state_->UnregisterModule(this); }
bool XModule::Matches(const std::string& name) const {
if (strcasecmp(xe::find_name_from_path(path_).c_str(), name.c_str()) == 0) {
return true;
}
if (strcasecmp(name_.c_str(), name.c_str()) == 0) {
return true;
}
if (strcasecmp(path_.c_str(), name.c_str()) == 0) {
return true;
}
return false;
}
void XModule::OnLoad() { kernel_state_->RegisterModule(this); }
X_STATUS XModule::GetSection(const char* name, uint32_t* out_section_data,