41#include "upnpconfig.h"
70typedef enum Upnp_Module
83typedef enum Upnp_LogLevel_e
99#define UPNP_PACKET UPNP_ERROR
104#define UPNP_DEFAULT_LOG_LEVEL UPNP_ALL
113#if defined NDEBUG && !defined UPNP_DEBUG_C
114 #define UpnpInitLog UpnpInitLog_Inlined
117 #ifndef UPNP_E_SUCCESS
118 #define UPNP_E_SUCCESS 0
127 Upnp_LogLevel log_level);
129#if defined NDEBUG && !defined UPNP_DEBUG_C
130 #define UpnpSetLogLevel UpnpSetLogLevel_Inlined
131static UPNP_INLINE void UpnpSetLogLevel_Inlined(Upnp_LogLevel log_level)
143#if defined NDEBUG && !defined UPNP_DEBUG_C
144 #define UpnpCloseLog UpnpCloseLog_Inlined
145static UPNP_INLINE void UpnpCloseLog_Inlined(
void) {}
155 const char *fileName,
157 const char *Ignored);
159#if defined NDEBUG && !defined UPNP_DEBUG_C
160 #define UpnpSetLogFileNames UpnpSetLogFileNames_Inlined
161static UPNP_INLINE void UpnpSetLogFileNames_Inlined(
162 const char *ErrFileName,
const char *ignored)
184#if defined NDEBUG && !defined UPNP_DEBUG_C
185 #define UpnpGetDebugFile UpnpGetDebugFile_Inlined
187 Upnp_LogLevel level, Dbg_Module module)
Defines constants that for some reason are not defined on some systems.
#define UPNP_EXPORT_SPEC
Export functions on WIN32 DLLs.
Definition UpnpGlobal.h:101
#define UPNP_INLINE
Declares an inline function.
Definition UpnpGlobal.h:115
#define UPNP_E_SUCCESS
The operation completed successfully.
Definition upnp.h:97
void UpnpSetLogLevel(Upnp_LogLevel log_level)
Set the log level (see Upnp_LogLevel).
Definition upnpdebug.c:116
FILE * UpnpGetDebugFile(Upnp_LogLevel level, Dbg_Module module)
Check if the module is turned on for debug and returns the file descriptor corresponding to the debug...
Definition upnpdebug.c:300
void UpnpSetLogFileNames(const char *fileName, const char *Ignored)
Set the name for the log file. There used to be 2 separate files. The second parameter has been kept ...
Definition upnpdebug.c:143
void UpnpCloseLog(void)
Closes the log files.
Definition upnpdebug.c:122
int UpnpInitLog(void)
Initialize the log files.
Definition upnpdebug.c:72