diff --git a/reactos/drivers/network/tcpip/include/debug.h b/reactos/drivers/network/tcpip/include/debug.h index af16b58769d..9b8664974f1 100644 --- a/reactos/drivers/network/tcpip/include/debug.h +++ b/reactos/drivers/network/tcpip/include/debug.h @@ -9,9 +9,9 @@ #ifndef __DEBUG_H #define __DEBUG_H -#define MIN_TRACE DPFLTR_WARNING_LEVEL -#define MID_TRACE DPFLTR_WARNING_LEVEL | DPFLTR_TRACE_LEVEL -#define MAX_TRACE DPFLTR_WARNING_LEVEL | DPFLTR_TRACE_LEVEL | DPFLTR_INFO_LEVEL +#define MIN_TRACE ((1 << DPFLTR_WARNING_LEVEL)) +#define MID_TRACE ((1 << DPFLTR_WARNING_LEVEL) | (1 << DPFLTR_TRACE_LEVEL)) +#define MAX_TRACE ((1 << DPFLTR_WARNING_LEVEL) | (1 << DPFLTR_TRACE_LEVEL) | (1 << DPFLTR_INFO_LEVEL)) #define DEBUG_CHECK 0x00000100 #define DEBUG_MEMORY 0x00000200 @@ -37,8 +37,8 @@ #define REMOVE_PARENS(...) __VA_ARGS__ #define TI_DbgPrint(_t_, _x_) \ - DbgPrintEx(DPFLTR_TCPIP_ID, (_t_) & DPFLTR_MASK, "(%s:%d) ", __FILE__, __LINE__), \ - DbgPrintEx(DPFLTR_TCPIP_ID, (_t_) & DPFLTR_MASK, REMOVE_PARENS _x_) + DbgPrintEx(DPFLTR_TCPIP_ID, (_t_) | DPFLTR_MASK, "(%s:%d) ", __FILE__, __LINE__), \ + DbgPrintEx(DPFLTR_TCPIP_ID, (_t_) | DPFLTR_MASK, REMOVE_PARENS _x_) #else /* DBG */ diff --git a/reactos/drivers/network/tcpip/tcpip/main.c b/reactos/drivers/network/tcpip/tcpip/main.c index 370b8fb90bc..84a53d120ec 100644 --- a/reactos/drivers/network/tcpip/tcpip/main.c +++ b/reactos/drivers/network/tcpip/tcpip/main.c @@ -9,14 +9,6 @@ */ #include "precomp.h" -#define NDEBUG - -#ifndef NDEBUG -DWORD DebugTraceLevel = DEBUG_ULTRA & ~(DEBUG_LOCK | DEBUG_PBUFFER); -#else -DWORD DebugTraceLevel = 0; -#endif /* NDEBUG */ - PDEVICE_OBJECT TCPDeviceObject = NULL; PDEVICE_OBJECT UDPDeviceObject = NULL; PDEVICE_OBJECT IPDeviceObject = NULL; @@ -861,9 +853,6 @@ DriverEntry( DueTime.QuadPart = -(LONGLONG)IP_TIMEOUT * 10000; KeSetTimerEx(&IPTimer, DueTime, IP_TIMEOUT, &IPTimeoutDpc); - /* ROS Hack: ideally, DebugTraceLevel variable should be removed */ - DbgSetDebugFilterState(DPFLTR_TCPIP_ID, DebugTraceLevel, TRUE); - return STATUS_SUCCESS; }