mirror of https://github.com/wolfSSL/wolfssh.git
Removed function definitions when DEBUG is disabled
parent
c3aa7ec540
commit
b68f98ae70
13
src/log.c
13
src/log.c
|
@ -99,6 +99,7 @@ int wolfSSH_LogEnabled(void)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef DEBUG_WOLFSSH
|
||||||
#ifndef WOLFSSH_NO_DEFAULT_LOGGING_CB
|
#ifndef WOLFSSH_NO_DEFAULT_LOGGING_CB
|
||||||
/* log level string */
|
/* log level string */
|
||||||
static const char* GetLogStr(enum wolfSSH_LogLevel level)
|
static const char* GetLogStr(enum wolfSSH_LogLevel level)
|
||||||
|
@ -133,7 +134,6 @@ static const char* GetLogStr(enum wolfSSH_LogLevel level)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void DefaultLoggingCb(enum wolfSSH_LogLevel level, const char *const msgStr)
|
void DefaultLoggingCb(enum wolfSSH_LogLevel level, const char *const msgStr)
|
||||||
{
|
{
|
||||||
char timeStr[24];
|
char timeStr[24];
|
||||||
|
@ -176,3 +176,14 @@ void wolfSSH_Log(enum wolfSSH_LogLevel level, const char *const fmt, ...)
|
||||||
if (logFunction)
|
if (logFunction)
|
||||||
logFunction(level, msgStr);
|
logFunction(level, msgStr);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#else
|
||||||
|
void DefaultLoggingCb(enum wolfSSH_LogLevel level, const char *const msgStr)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
void wolfSSH_Log(enum wolfSSH_LogLevel level, const char *const fmt, ...)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
#endif /* DEBUG_WOLFSSH */
|
||||||
|
|
Loading…
Reference in New Issue