diff --git a/Sparkle/SULog.h b/Sparkle/SULog.h index c09ea60a..49c7ec3c 100644 --- a/Sparkle/SULog.h +++ b/Sparkle/SULog.h @@ -19,7 +19,7 @@ typedef NS_ENUM(uint8_t, SULogLevel) { // Logging utlity function that is thread-safe // On 10.12 or later this uses os_log // Otherwise on older systems this uses ASL -// For debugging command line tools, you may have to use Console.app to view log messages +// For debugging command line tools, you may have to use Console.app or log(1) to view log messages // Try to keep log messages as compact/short as possible void SULog(SULogLevel level, NSString *format, ...) NS_FORMAT_FUNCTION(2, 3); diff --git a/Sparkle/SULog.m b/Sparkle/SULog.m index ddaf0bdf..aa3192de 100644 --- a/Sparkle/SULog.m +++ b/Sparkle/SULog.m @@ -40,6 +40,7 @@ void SULog(SULogLevel level, NSString *format, ...) const char *subsystem = [[bundleIdentifier stringByAppendingString:@".Sparkle"] UTF8String]; #pragma clang diagnostic push #pragma clang diagnostic ignored "-Wpartial-availability" + // This creates a thread-safe object logger = os_log_create(subsystem, "Sparkle"); #pragma clang diagnostic pop } else {