diff options
Diffstat (limited to 'Firebase')
-rw-r--r-- | Firebase/Core/FIRLogger.m | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/Firebase/Core/FIRLogger.m b/Firebase/Core/FIRLogger.m index 7abac19..03f8a79 100644 --- a/Firebase/Core/FIRLogger.m +++ b/Firebase/Core/FIRLogger.m @@ -174,7 +174,14 @@ void FIRSetLoggerLevel(FIRLoggerLevel loggerLevel) { }); } -BOOL FIRIsLoggableLevel(FIRLoggerLevel loggerLevel, BOOL analyticsComponent) { +/** + * Check if the level is high enough to be loggable. + * + * Analytics can override the log level with an intentional race condition. + * Add the attribute to get a clean thread sanitizer run. + */ +__attribute__((no_sanitize("thread"))) BOOL FIRIsLoggableLevel(FIRLoggerLevel loggerLevel, + BOOL analyticsComponent) { FIRLoggerInitializeASL(); if (sFIRLoggerDebugMode) { return YES; |