MCPcopy Create free account
hub / github.com/LUX-Core/lux / DetectNoWait

Method DetectNoWait

src/cryptopp/wait.cpp:87–107  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

85}
86
87void WaitObjectContainer::DetectNoWait(LastResultType result, CallStack const& callStack)
88{
89 if (result == m_lastResult && m_noWaitTimer.ElapsedTime() > 1000)
90 {
91 if (m_sameResultCount > m_noWaitTimer.ElapsedTime())
92 {
93 if (m_tracer)
94 {
95 std::string desc = "No wait loop detected - m_lastResult: ";
96 desc.append(IntToString(m_lastResult)).append(", call stack:");
97 for (CallStack const* cs = &callStack; cs; cs = cs->Prev())
98 desc.append("\n- ").append(cs->Format());
99 m_tracer->TraceNoWaitLoop(desc);
100 }
101 try { throw 0; } catch (...) {} // help debugger break
102 }
103
104 m_noWaitTimer.StartTimer();
105 m_sameResultCount = 0;
106 }
107}
108
109void WaitObjectContainer::SetNoWait(CallStack const& callStack)
110{

Callers

nothing calls this directly

Calls 6

IntToStringFunction · 0.85
ElapsedTimeMethod · 0.80
FormatMethod · 0.80
StartTimerMethod · 0.80
appendMethod · 0.45
PrevMethod · 0.45

Tested by

no test coverage detected