LogInit

Table of Contents

LogInit

Description

Initialize logging subsystem

Note

Is lazily called if not called by user at start of program.

Parameters

NameDirectionDescription
redirectinWhen true, redirect output to temporary file

Success

Logging system ready for use

Failure

Logging remains uninitialized (will lazy-init later)

Usage example (Cross-references)

    }
    
    void LogInit(bool redirect) {
    if (redirect) {
    // Get the current time
    // Initialize log if not already
    if (!stderror) {
    LogInit(false);
    }
    }
    
    LogInit(false);
    
    const char *config_path = argv[1];
    
    int main(int argc, char **argv) {
    LogInit(false);
    
    if (argc < 2 || argc > 3) {

Share :

Related Posts

LOG_INFO

LOG_INFO Description Writes an informational log message. …[in] : Format string and arguments following printf-style syntax.

Read More

NEW

NEW Description Allocates zero-initialized memory for a type.

Read More

SysAbort

SysAbort Description Custom abort function that can be redirected for testing purposes. By default, this calls the standard abort() function. If a callback is set via SysSetAbortCallback, it calls the callback instead.

Read More