Skip to content

Commit

Permalink
Fix race on message handler setup
Browse files Browse the repository at this point in the history
  • Loading branch information
0cyn committed Apr 10, 2023
1 parent c6862f2 commit faaa543
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions Workflow.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -105,8 +105,6 @@ void Workflow::inlineMethodCalls(AnalysisContextRef ac)
if (GlobalState::viewIsIgnored(bv))
return;

auto messageHandler = GlobalState::messageHandler(bv);

const auto log = BinaryNinja::LogRegistry::GetLogger(PluginLoggerName);

// Ignore the view if it has an unsupported architecture.
Expand Down Expand Up @@ -187,6 +185,7 @@ void Workflow::inlineMethodCalls(AnalysisContextRef ac)
GlobalState::storeAnalysisInfo(bv, info);
}
}
auto messageHandler = GlobalState::messageHandler(bv);

if (!messageHandler->hasMessageSendFunctions()) {
log->LogError("Cannot perform Objective-C IL cleanup; no objc_msgSend candidates found");
Expand Down

0 comments on commit faaa543

Please sign in to comment.