mirror of
https://github.com/intel/llvm.git
synced 2026-02-04 11:38:04 +08:00
Revert "[lldb] Fix bug to update process public run lock with process state"
This reverts commit 14f00213b2.
This commit is contained in:
@@ -1355,6 +1355,8 @@ Status Process::Resume() {
|
||||
return error;
|
||||
}
|
||||
|
||||
static const char *g_resume_sync_name = "lldb.Process.ResumeSynchronous.hijack";
|
||||
|
||||
Status Process::ResumeSynchronous(Stream *stream) {
|
||||
Log *log(GetLog(LLDBLog::State | LLDBLog::Process));
|
||||
LLDB_LOGF(log, "Process::ResumeSynchronous -- locking run lock");
|
||||
@@ -1365,7 +1367,7 @@ Status Process::ResumeSynchronous(Stream *stream) {
|
||||
}
|
||||
|
||||
ListenerSP listener_sp(
|
||||
Listener::MakeListener(ResumeSynchronousHijackListenerName.data()));
|
||||
Listener::MakeListener(g_resume_sync_name));
|
||||
HijackProcessEvents(listener_sp);
|
||||
|
||||
Status error = PrivateResume();
|
||||
@@ -1391,8 +1393,9 @@ Status Process::ResumeSynchronous(Stream *stream) {
|
||||
|
||||
bool Process::StateChangedIsExternallyHijacked() {
|
||||
if (IsHijackedForEvent(eBroadcastBitStateChanged)) {
|
||||
llvm::StringRef hijacking_name = GetHijackingListenerName();
|
||||
if (hijacking_name.starts_with("lldb.internal"))
|
||||
const char *hijacking_name = GetHijackingListenerName();
|
||||
if (hijacking_name &&
|
||||
strcmp(hijacking_name, g_resume_sync_name))
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
@@ -1400,8 +1403,9 @@ bool Process::StateChangedIsExternallyHijacked() {
|
||||
|
||||
bool Process::StateChangedIsHijackedForSynchronousResume() {
|
||||
if (IsHijackedForEvent(eBroadcastBitStateChanged)) {
|
||||
llvm::StringRef hijacking_name = GetHijackingListenerName();
|
||||
if (hijacking_name == ResumeSynchronousHijackListenerName)
|
||||
const char *hijacking_name = GetHijackingListenerName();
|
||||
if (hijacking_name &&
|
||||
strcmp(hijacking_name, g_resume_sync_name) == 0)
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
|
||||
Reference in New Issue
Block a user