mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-08-08 09:09:04 +00:00
CheatSearchWidget: Make use of CPUThreadGuard parameter in UpdateTableRows
Previously, the parameter wasn't being used, because it was being shadowed by another CPUThreadGuard at its only would-be usage point.
This commit is contained in:
parent
b4bfc4feba
commit
915e43dfba
1 changed files with 2 additions and 7 deletions
|
@ -388,15 +388,10 @@ bool CheatSearchWidget::UpdateTableRows(const Core::CPUThreadGuard& guard, const
|
||||||
{
|
{
|
||||||
const bool update_status_text = source == UpdateSource::User;
|
const bool update_status_text = source == UpdateSource::User;
|
||||||
|
|
||||||
std::unique_ptr<Cheats::CheatSearchSessionBase> tmp =
|
auto tmp = m_session->ClonePartial(begin_index, end_index);
|
||||||
m_session->ClonePartial(begin_index, end_index);
|
|
||||||
tmp->SetFilterType(Cheats::FilterType::DoNotFilter);
|
tmp->SetFilterType(Cheats::FilterType::DoNotFilter);
|
||||||
|
|
||||||
const Cheats::SearchErrorCode error_code = [&tmp] {
|
const Cheats::SearchErrorCode error_code = tmp->RunSearch(guard);
|
||||||
Core::CPUThreadGuard guard(Core::System::GetInstance());
|
|
||||||
return tmp->RunSearch(guard);
|
|
||||||
}();
|
|
||||||
|
|
||||||
if (error_code != Cheats::SearchErrorCode::Success)
|
if (error_code != Cheats::SearchErrorCode::Success)
|
||||||
{
|
{
|
||||||
if (update_status_text)
|
if (update_status_text)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue