\hypertarget{interface_2logger_8c}{
\section{src/interface/logger.c File Reference}
\label{interface_2logger_8c}\index{src/interface/logger.c@{src/interface/logger.c}}
}
{\ttfamily \#include $<$stdlib.h$>$}\par
{\ttfamily \#include $<$stdarg.h$>$}\par
{\ttfamily \#include \char`\"{}logger.h\char`\"{}}\par
{\ttfamily \#include \char`\"{}interface/logger.h\char`\"{}}\par
Include dependency graph for logger.c:
\subsection*{Functions}
\begin{DoxyCompactItemize}
\item 
void \hyperlink{interface_2logger_8c_a9053743a944f1faef3866efaa52d3c7f}{loggerLog} (void $\ast$\_\-object, \hyperlink{logger_8h_a63296c69f4b9bf51d6756a5d2c482d1e}{logger\_\-level} level, const char $\ast$const fmt,...)
\end{DoxyCompactItemize}


\subsection{Function Documentation}
\hypertarget{interface_2logger_8c_a9053743a944f1faef3866efaa52d3c7f}{
\index{interface/logger.c@{interface/logger.c}!loggerLog@{loggerLog}}
\index{loggerLog@{loggerLog}!interface/logger.c@{interface/logger.c}}
\subsubsection[{loggerLog}]{\setlength{\rightskip}{0pt plus 5cm}void loggerLog (
\begin{DoxyParamCaption}
\item[{void $\ast$}]{\_\-object, }
\item[{{\bf logger\_\-level}}]{level, }
\item[{const char $\ast$const}]{fmt, }
\item[{}]{...}
\end{DoxyParamCaption}
)}}
\label{interface_2logger_8c_a9053743a944f1faef3866efaa52d3c7f}


Definition at line 13 of file logger.c.


\begin{DoxyCode}
                                                                           {
        Logger object = _object;

        if (level >= object->min_level) {
                char *  msg      = NULL;
                size_t  msg_size = 0;
                va_list params;

                va_start(params, fmt);
                msg_size = vsnprintf(msg, msg_size, fmt, params);
                va_end(params);

                msg = malloc(msg_size + 1);

                va_start(params, fmt);
                vsnprintf(msg, msg_size + 1, fmt, params);
                va_end(params);

                CALL(_object, Logger, log, level, msg);

                free(msg);
        }
}
\end{DoxyCode}


Here is the caller graph for this function:


