8
0
mirror of https://github.com/FirebirdSQL/firebird.git synced 2025-01-22 20:03:02 +01:00

Fixed #7139: With multiple trace sessions user may receive trace events related to engine's requests

This commit is contained in:
AlexPeshkoff 2022-03-01 18:14:13 +03:00
parent b63707d06a
commit 9814fd6145
2 changed files with 8 additions and 2 deletions

View File

@ -222,6 +222,8 @@ void TraceManager::update_sessions()
}
// add new sessions
new_needs = trace_needs;
trace_needs = 0;
while (newSessions.hasData())
{
TraceSession* s = newSessions.pop();
@ -234,6 +236,10 @@ void TraceManager::update_sessions()
{
trace_needs = 0;
}
else
{
trace_needs = new_needs;
}
}
void TraceManager::update_session(const TraceSession& session)
@ -344,7 +350,7 @@ void TraceManager::update_session(const TraceSession& session)
sesInfo.ses_id = session.ses_id;
trace_sessions.add(sesInfo);
trace_needs |= info->factory->trace_needs();
new_needs |= info->factory->trace_needs();
}
else if (status->getState() & IStatus::STATE_ERRORS)
{

View File

@ -163,7 +163,7 @@ private:
Attachment* attachment;
Service* service;
const char* filename;
NotificationNeeds trace_needs;
NotificationNeeds trace_needs, new_needs;
// This structure should be POD-like to be stored in Array
struct FactoryInfo