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

Fixed bug #6918 : Service detach is always traced

This commit is contained in:
hvlad 2021-08-10 00:23:48 +03:00
parent 7075df2dab
commit 8c557c05db

View File

@ -915,8 +915,11 @@ void Service::detach()
// save it cause after call to finish() we can't access class members any more
const bool localDoShutdown = svc_do_shutdown;
TraceServiceImpl service(this);
svc_trace_manager->event_service_detach(&service, ITracePlugin::RESULT_SUCCESS);
if (svc_trace_manager->needs(ITraceFactory::TRACE_EVENT_SERVICE_DETACH))
{
TraceServiceImpl service(this);
svc_trace_manager->event_service_detach(&service, ITracePlugin::RESULT_SUCCESS);
}
// Mark service as detached.
finish(SVC_detached);