Logging: Fix server hangs when using log.WithSuffix (#45213)

Fixes a problem where server hangs if setting 
GF_DATABASE_LOG_QUERIES=true.

Ref #44925
This commit is contained in:
Marcus Efraimsson
2022-02-10 12:51:51 +01:00
committed by GitHub
parent e48baefd32
commit ca311bf94f
2 changed files with 109 additions and 46 deletions
+1 -1
View File
@@ -206,7 +206,7 @@ func with(ctxLogger *ConcreteLogger, withFunc func(gokitlog.Logger, ...interface
return ctxLogger
}
ctxLogger.Swap(withFunc(&ctxLogger.SwapLogger, ctx...))
ctxLogger.Swap(withFunc(ctxLogger.GetLogger(), ctx...))
return ctxLogger
}