windows-nt/Source/XPSP1/NT/multimedia/media/dplay/misc/logit.h
2020-09-26 16:20:57 +08:00

38 lines
883 B
C
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

#ifndef __LOG_IT__
#define __LOG_IT__
typedef enum
{
LOG,
ABORT,
EXIT,
INFO
} LOG_TYPE;
extern void cdecl lpf(LPSTR szFormat, ...);
#ifdef DEBUG
#define TSHELL_LOG(a) LogIt((a), __FILE__, __LINE__, LOG) ; bb = FALSE
#define TSHELL_INFO(a) LogIt((a), __FILE__, __LINE__, INFO)
#define TSHELL_ABORT(a) LogIt((a), __FILE__, __LINE__, ABORT); bb = FALSE; goto abort
#define TSHELL_EXIT(a) LogIt((a), __FILE__, __LINE__, EXIT); return(FALSE)
#define DBGARG __FILE__, __LINE__, INFO
#define DBG_INFO(a) LogIt2 a
#else
#define TSHELL_LOG(a) bb = FALSE
#define TSHELL_INFO(a)
#define TSHELL_ABORT(a) bb = FALSE; goto abort
#define TSHELL_EXIT(a) return(FALSE)
#define DBG_INFO(a)
#endif
void LogIt(char *chMsg, char *chFile, UINT uiLine, LOG_TYPE log);
void LogIt2(char *chFile, UINT uiLine, LOG_TYPE log, LPSTR szFormat, ...);
#endif