Code/Resource
Windows Develop
Linux-Unix program
Internet-Socket-Network
Web Server
Browser Client
Ftp Server
Ftp Client
Browser Plugins
Proxy Server
Email Server
Email Client
WEB Mail
Firewall-Security
Telnet Server
Telnet Client
ICQ-IM-Chat
Search Engine
Sniffer Package capture
Remote Control
xml-soap-webservice
P2P
WEB(ASP,PHP,...)
TCP/IP Stack
SNMP
Grid Computing
SilverLight
DNS
Cluster Service
Network Security
Communication-Mobile
Game Program
Editor
Multimedia program
Graph program
Compiler program
Compress-Decompress algrithms
Crypt_Decrypt algrithms
Mathimatics-Numerical algorithms
MultiLanguage
Disk/Storage
Java Develop
assembly language
Applications
Other systems
Database system
Embeded-SCM Develop
FlashMX/Flex
source in ebook
Delphi VCL
OS Develop
MiddleWare
MPI
MacOS develop
LabView
ELanguage
Software/Tools
E-Books
Artical/Document
Debug.cpp
Package: ipfilter.zip [view]
Upload User: nnxzhh
Upload Date: 2007-01-11
Package Size: 742k
Code Size: 2k
Category:
Firewall-Security
Development Platform:
WINDOWS
- ///////////////////////////////////////////////////////////////////////////////
- //
- // (C) Copyright 1999 - 2000 Mark Roddy
- // All Rights Reserved
- //
- // Hollis Technology Solutions
- // 94 Dow Road
- // Hollis, NH 03049
- // info@hollistech.com
- //
- // Synopsis:
- //
- //
- // Version Information:
- //
- // $Header: /iphook/sys/driver/Debug.cpp 4 4/23/00 5:10p Markr $
- //
- ///////////////////////////////////////////////////////////////////////////////
- #include <stdarg.h>
- #include "stdio.h"
- #include "stddef.h"
- #include "htsglib.h"
- HTS_DEBUG_THIS_FILE
- ULONG HtsDebugLevel = HTS_DEBUG_LOW;
- #if DBG
- #define DEBUG_BUFFER_SIZE 256
- void
- HtsDebugPrint(
- ULONG Level,
- PCHAR Format,
- ...
- )
- {
- CHAR buffer[DEBUG_BUFFER_SIZE];
- va_list args;
- va_start(args, Format);
- if ((Level & HTS_DEBUG_MASK) >= HtsDebugLevel) {
- _vsnprintf(buffer, DEBUG_BUFFER_SIZE, Format, args);
- DbgPrint(buffer);
- }
- va_end(args);
- }
- #else
- void
- HtsDebugPrint(
- ULONG Level,
- PCHAR Format,
- ...
- )
- {
- }
- #endif
- ULONG HtsDriverId = 0;
- void HtsBugCheck(PCHAR message, ULONG param1, ULONG param2, ULONG param3, ULONG param4)
- {
- DbgPrint("nnKernel Failure: "%s" nnn"
- "[ System Halting ]n", message);
- KeBugCheckEx(BUGCODE_ID_DRIVER, param1, param2, param3, param4);
- }
- ULONG HtsExceptionFilter( ULONG Code, PEXCEPTION_POINTERS pointers)
- {
- PEXCEPTION_RECORD ExceptionRecord;
- PCONTEXT Context;
- ExceptionRecord = pointers->ExceptionRecord;
- Context = pointers->ContextRecord;
- #if DBG
- DbgPrint("*************** Exception Failure **************************n");
- DbgPrint("n");
- DbgPrint(" An unexpected exception occurred.n");
- DbgPrint(" Exception record at %x Context record at %xn",
- ExceptionRecord, Context);
- DbgPrint(" WindBag: execute "!cxr %x; !exr %x; !kb" for stacktracenn",
- Context, ExceptionRecord);
- DbgBreakPoint();
- #endif
- return EXCEPTION_EXECUTE_HANDLER;
- }
- ///////////////////////////////////////////////////////////////////////////////
- //
- // Change History Log
- //
- // $Log: /iphook/sys/driver/Debug.cpp $
- //
- // 4 4/23/00 5:10p Markr
- //
- // 3 1/27/00 10:35p Markr
- // Prepare to release!
- //
- ///////////////////////////////////////////////////////////////////////////////