亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲蟲下載站

?? filemon.c

?? Socket異步通信示程序代碼下載.非常直觀
?? C
?? 第 1 頁 / 共 4 頁
字號(hào):
/******************************************************************************
*
*       FileMon - File System Monitor for Windows NT
*		
*		Copyright (c) 1996-1998 Mark Russinovich and Bryce Cogswell
*
*		See readme.txt for tersma and conditions.
*
*    	PROGRAM: FileMon.c
*
*    	PURPOSE: Communicates with the FileMon driver to display 
*		file system activity information.
*
******************************************************************************/
#include <windows.h>    // includes basic windows functionality
#include <windowsx.h>
#include <tchar.h>
#include <commctrl.h>   // includes the common control header
#include <stdio.h>
#include <string.h>
#include <winioctl.h>
#include "resource.h"
#include "ioctlcmd.h"

#include "instdrv.h"

// this typedef, present in newer system include files,
// supports the building filemon on older systems
typedef struct 
{
    DWORD cbSize;
    DWORD dwMajorVersion;
    DWORD dwMinorVersion;
    DWORD dwBuildNumber;
    DWORD dwPlatformID;
} DLLVERSIONINFO_, *PDLLVERSIONINFO_;

HRESULT (CALLBACK *pDllGetVersionProc)( PDLLVERSIONINFO_ pdvi );

// Set this to 0 for a non-processor specific version that does not get
// process names from the device driver
#define GETPROCESS 1

//
// Application name for message boxes
//
#define APPNAME			_T("Filemon")

// toolbar height plus the borders
#define TOOLBARHEIGHT	28

// Number of columns in the listview
#define NUMCOLUMNS	7

// Variables/definitions for the driver that performs the actual monitoring.
#define				SYS_FILE		_T("FILEMON.SYS")
#define				SYS_NAME		_T("FILEMON")
static HANDLE		sys_handle		= INVALID_HANDLE_VALUE;

// Drive type names
#define DRVUNKNOWN		0
#define DRVFIXED		1
#define DRVREMOTE		2
#define DRVRAM			3
#define DRVCD			4
#define DRVREMOVE		5
TCHAR DrvNames[][32] = {
	_T("UNKNOWN"),
	_T("FIXED"),
	_T("REMOTE"),
	_T("RAM"),
	_T("CD"),
	_T("REMOVEABLE"),
};	

#define POSVERSION 360

// Position settings data structure 
typedef struct {
	int		posversion;
	int		left;
	int		top;
	int		width;
	int		height;
	DWORD	column[NUMCOLUMNS];
	DWORD	curdriveset;
	DWORD	historydepth;
	BOOLEAN maximized;
	BOOLEAN timeduration;
	FILTER  filter;
} POSITION_SETTINGS;

// typedef for balloon popup
typedef struct {
	WCHAR	itemText[1024];
	POINT	itemPosition;
} ITEM_CLICK, *PITEM_CLICK;

// drives that are hooked
DWORD	CurDriveSet;

// The variable that holds the position settings
POSITION_SETTINGS	PositionInfo;

// toolbar constants
#define ID_TOOLBAR         1

// defined for comtl32.dll version 4.7
#define TOOLBAR_FLAT		0x800

// button definitions

// for installations that support flat style
TBBUTTON tbButtons[] = {
	{ 0, 0, TBSTATE_ENABLED, TBSTYLE_SEP, 0L, 0},
	{ 0, IDM_SAVE, TBSTATE_ENABLED, TBSTYLE_BUTTON, 0L, 0},
	{ 8, 0, 0, TBSTYLE_BUTTON, 0L, 0},
	{ 2, IDM_CAPTURE, TBSTATE_ENABLED, TBSTYLE_BUTTON, 0L, 0},
	{ 4, IDM_AUTOSCROLL, TBSTATE_ENABLED, TBSTYLE_BUTTON, 0L, 0},
	{ 6, IDM_CLEAR, TBSTATE_ENABLED, TBSTYLE_BUTTON, 0L, 0},
	{ 0, 0, TBSTATE_ENABLED, TBSTYLE_SEP, 0L, 0},
	{ 9, IDM_TIME, TBSTATE_ENABLED, TBSTYLE_BUTTON, 0L, 0 },	
	{ 8, 0, 0, TBSTYLE_BUTTON, 0L, 0},
	{ 5, IDM_FILTER, TBSTATE_ENABLED, TBSTYLE_BUTTON, 0L, 0},
	{ 8, 0, 0, TBSTYLE_BUTTON, 0L, 0},
	{ 7, IDM_FIND, TBSTATE_ENABLED, TBSTYLE_BUTTON, 0L, 0},
	{ 8, 0, 0, TBSTYLE_BUTTON, 0L, 0},
};
#define NUMBUTTONS		13

// for older installations
TBBUTTON tbButtonsOld[] = {
	{ 0, 0, TBSTATE_ENABLED, TBSTYLE_SEP, 0L, 0},
	{ 0, IDM_SAVE, TBSTATE_ENABLED, TBSTYLE_BUTTON, 0L, 0},
	{ 0, 0, TBSTATE_ENABLED, TBSTYLE_SEP, 0L, 0},
	{ 2, IDM_CAPTURE, TBSTATE_ENABLED, TBSTYLE_BUTTON, 0L, 0},
	{ 4, IDM_AUTOSCROLL, TBSTATE_ENABLED, TBSTYLE_BUTTON, 0L, 0},
	{ 6, IDM_CLEAR, TBSTATE_ENABLED, TBSTYLE_BUTTON, 0L, 0},	
	{ 0, 0, TBSTATE_ENABLED, TBSTYLE_SEP, 0L, 0},
	{ 9, IDM_TIME, TBSTATE_ENABLED, TBSTYLE_BUTTON, 0L, 0 },	
	{ 0, 0, TBSTATE_ENABLED, TBSTYLE_SEP, 0L, 0},
	{ 5, IDM_FILTER, TBSTATE_ENABLED, TBSTYLE_BUTTON, 0L, 0},
	{ 0, 0, TBSTATE_ENABLED, TBSTYLE_SEP, 0L, 0},
	{ 7, IDM_FIND, TBSTATE_ENABLED, TBSTYLE_BUTTON, 0L, 0},
};

#define NUMBUTTONSOLD	12


// Buffer into which driver can copy statistics
char				Stats[ MAX_STORE ];
// Current fraction of buffer filled
DWORD				StatsLen;

// Search string
TCHAR				FindString[256];
FINDREPLACE			FindTextInfo;
DWORD				FindFlags = FR_DOWN;
BOOLEAN				PrevMatch;
TCHAR				PrevMatchString[256];				

// Application instance handle
HINSTANCE			hInst;

// Misc globals
HWND				hWndFind = NULL;
UINT				findMessageID;
HWND				hWndList;
HWND				hBalloon = NULL;
BOOLEAN				Capture = TRUE;
BOOLEAN				Autoscroll = TRUE;

// listview size limiting
DWORD				MaxLines = 0;
DWORD				LastRow = 0;

// is time absolute or duration?
BOOLEAN				TimeIsDuration;

// Filter-related
FILTER				FilterDefinition;

// For info saving
TCHAR				szFileName[256];
BOOLEAN				FileChosen = FALSE;

// General buffer for storing temporary strings
static TCHAR		msgbuf[ 257 ];

// General cursor manipulation
HCURSOR 			hSaveCursor;
HCURSOR 			hHourGlass;

// performance counter frequency
LARGE_INTEGER		PerfFrequency;


//functions
BOOL 				InitApplication( HANDLE );
HWND 				InitInstance( HANDLE, int );
DWORD 				Hook_Drives( HMENU DriveMenu, DWORD MaxDriveSet, DWORD CurDriveSet ); 
HWND 				CreateList( HWND );
void 				UpdateStatistics( HWND hWnd, HWND hWndList, BOOL Clear );
int 				CALLBACK ListCompareProc( LPARAM lParam1, LPARAM lParam2, LPARAM lParamSort );
void				SaveFile( HWND hDlg, HWND listbox, BOOLEAN SaveAs );


/******************************************************************************
*
*	FUNCTION:	Abort:
*
*	PURPOSE:	Handles emergency exit conditions.
*
*****************************************************************************/
void Abort( HWND hWnd, TCHAR * Msg )
{
	LPVOID	lpMsgBuf;
	TCHAR	errmsg[256];
	DWORD	error = GetLastError();
 
	FormatMessage( FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_FROM_SYSTEM,
					NULL, GetLastError(), 
					MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT),
					(LPTSTR) &lpMsgBuf, 0, NULL );
	UnloadDeviceDriver( SYS_NAME );
	wsprintf(errmsg, _T("%s: %s"), Msg, lpMsgBuf );
	if( error == ERROR_INVALID_HANDLE ) 
		wsprintf(errmsg, _T("%s\nMake sure that you are an administrator and that ")
			_T("Filemon is located on a local drive."), errmsg  );
	MessageBox( hWnd, errmsg, _T("Filemon"), MB_OK|MB_ICONERROR );
	PostQuitMessage( 1 );
	LocalFree( lpMsgBuf );
}

/******************************************************************************
*
*	FUNCTION:	BalloonDialog
*
*	PURPOSE:	Dialog function for home-brewed balloon help.
*
******************************************************************************/
LONG APIENTRY BalloonDialog( HWND hDlg, UINT message, UINT wParam, LONG lParam )
{
	static ITEM_CLICK	ctx;
	static RECT			rect;
	static HFONT		hfont;
	LPCREATESTRUCT		lpcs;
	HDC					hdc;
	LOGFONT				lf;

	switch (message) {
		case WM_CREATE:

			lpcs = (void *)lParam;
			ctx = *(PITEM_CLICK) lpcs->lpCreateParams;
			hdc = GetDC( hDlg );

			// Get font
			if ( hfont == NULL )  {
				GetObject( GetStockObject(SYSTEM_FONT), sizeof lf, &lf ); 
				lf.lfWeight = FW_NORMAL;
				lf.lfHeight = 8;
				lf.lfWidth  = 0;
				wcscpy( lf.lfFaceName, _T("MS Sans Serif") );
 				hfont = CreateFontIndirect( &lf ); 
			} 

			// Compute size of required rectangle
			rect.left	= 0;
			rect.top	= 0;
			rect.right	= lpcs->cx;
			rect.bottom	= lpcs->cy;
			SelectObject( hdc, hfont );
			DrawText( hdc, ctx.itemText, -1, &rect, 
						DT_NOCLIP|DT_LEFT|DT_NOPREFIX|DT_WORDBREAK|DT_CALCRECT );

			// Move and resize window
			if( ctx.itemPosition.x - 5 + rect.right + 10 >
				 GetSystemMetrics(SM_CXFULLSCREEN) ) {

				 ctx.itemPosition.x = GetSystemMetrics(SM_CXFULLSCREEN) -
							(rect.right+10-5);
			}
			MoveWindow( hDlg, 
						ctx.itemPosition.x-5, ctx.itemPosition.y+10, 
						rect.right + 10, 
						rect.bottom + 10,
						TRUE );

			// Adjust rectangle so text is centered
			rect.left	+= 5;
			rect.right	+= 5;
			rect.top	+= 5;
			rect.bottom	+= 5;
			break;

		case WM_PAINT:
			hdc = GetDC( hDlg );

			// Set colors
			SetTextColor( hdc, 0x00000000 );
			SetBkMode( hdc, TRANSPARENT );
			SelectObject( hdc, hfont );
			DrawText( hdc, ctx.itemText, -1, &rect, 
						DT_NOCLIP|DT_LEFT|DT_NOPREFIX|DT_WORDBREAK );
			break;

		case WM_MOUSEMOVE:
		case WM_CLOSE:	
			hBalloon = NULL;
			DestroyWindow( hDlg );
			break;
	}

    return DefWindowProc( hDlg, message, wParam, lParam );
}


/******************************************************************************
*
*	FUNCTION:	FindInListview:
*
*	PURPOSE:	Searches for a string in the listview. Note: its okay if
*				items are being added to the list view or the list view
*				is cleared while this search is in progress - the effect
*				is harmless.
*
*****************************************************************************/
BOOLEAN FindInListview(HWND hWnd, LPFINDREPLACE FindInfo )
{
	int		currentItem;
	DWORD	i;
	int		subitem, numItems;
	TCHAR	fieldtext[256];
	BOOLEAN match = FALSE;
	TCHAR	errmsg[256];
	BOOLEAN	goUp;

	// get the search direction
	goUp = ((FindInfo->Flags & FR_DOWN) == FR_DOWN);

	// initialize stuff
	if( !(numItems = ListView_GetItemCount( hWndList ))) {

		MessageBox( hWnd, _T("No items to search"), _T("Filemon"), 
			MB_OK|MB_ICONWARNING );
		return FALSE;
	}

	// find the item with the focus
	currentItem = ListView_GetNextItem( hWndList, 0, LVNI_SELECTED );

	// if no current item, start at the top or the bottom
	if( currentItem == -1 ) {
		if( goUp )
			currentItem = 0;
		else {
			if( PrevMatch ) {
				wsprintf(errmsg, _T("Cannot find string \"%s\""), FindInfo->lpstrFindWhat );
				MessageBox( hWnd, errmsg, _T("Filemon"), MB_OK|MB_ICONWARNING );
				return FALSE;
			}
			currentItem = numItems;
		}
	}

	// if we're continuing a search, start with the next item
	if( PrevMatch && !wcscmp( FindString, PrevMatchString ) ) {
		if( goUp ) currentItem++;
		else currentItem--;

		if( (!goUp && currentItem < 0) ||
			(goUp && currentItem >= numItems )) {

			wsprintf(errmsg, _T("Cannot find string \"%s\""), FindInfo->lpstrFindWhat );
			MessageBox( hWnd, errmsg, APPNAME, MB_OK|MB_ICONWARNING );
			return FALSE;
		}
	}

	// loop through each item looking for the string
	while( 1 ) {

		// get the item text
		for( subitem = 0; subitem < NUMCOLUMNS; subitem++ ) {
			fieldtext[0] = 0;
			ListView_GetItemText( hWndList, currentItem, subitem, fieldtext, 256 );

			// make sure enought string for a match
			if( wcslen( fieldtext ) < wcslen( FindInfo->lpstrFindWhat ))
				continue;

			// do a scan all the way through for the substring
			if( FindInfo->Flags & FR_WHOLEWORD ) {

				i = 0;
				while( fieldtext[i] ) {
					while( fieldtext[i] && fieldtext[i] != ' ' ) i++;
					if( FindInfo->Flags & FR_MATCHCASE ) 
						match = !wcscmp( fieldtext, FindInfo->lpstrFindWhat );
					else
						match = !wcsicmp( fieldtext, FindInfo->lpstrFindWhat );
					if( match) break;
					i++;
				}	
			} else {
				for( i = 0; i < wcslen( fieldtext ) - wcslen(FindInfo->lpstrFindWhat)+1; i++ ) {
					if( FindInfo->Flags & FR_MATCHCASE ) 
						match = !wcsncmp( &fieldtext[i], FindInfo->lpstrFindWhat, 
											wcslen(FindInfo->lpstrFindWhat) );
					else
						match = !wcsnicmp( &fieldtext[i], FindInfo->lpstrFindWhat,
											wcslen(FindInfo->lpstrFindWhat) );
					if( match ) break;
				}		
			}

			if( match ) {

				wcscpy( PrevMatchString, FindInfo->lpstrFindWhat );
				PrevMatch = TRUE;
				ListView_SetItemState( hWndList, currentItem, 
							LVIS_SELECTED|LVIS_FOCUSED,
							LVIS_SELECTED|LVIS_FOCUSED );
				ListView_EnsureVisible( hWndList, currentItem, FALSE ); 
				SetFocus( hWndList );
				return TRUE;
			}
		}
		currentItem = currentItem + (goUp ? 1:-1);
		if( !currentItem || currentItem == numItems+1 ) {
			// end of the road
			break;
		}
	}
	wsprintf(errmsg, _T("Cannot find string \"%s\""), FindInfo->lpstrFindWhat );
	MessageBox( hWnd, errmsg, APPNAME, MB_OK|MB_ICONWARNING );
	return FALSE;
}


?? 快捷鍵說明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號(hào) Ctrl + =
減小字號(hào) Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
麻豆成人久久精品二区三区红 | 欧美狂野另类xxxxoooo| www.激情成人| 成人午夜激情在线| 国产成人免费网站| 成人美女在线视频| aa级大片欧美| 色婷婷av一区二区三区之一色屋| yourporn久久国产精品| 9人人澡人人爽人人精品| 成人app在线观看| www.成人网.com| 91国产丝袜在线播放| 欧美精品视频www在线观看| 国产精品每日更新| 欧美精品乱码久久久久久按摩| 99久久久免费精品国产一区二区| 成人免费毛片aaaaa**| 国产一区二区三区高清播放| 成人免费看视频| 91麻豆国产自产在线观看| 在线观看视频欧美| 制服丝袜中文字幕一区| 日韩一区二区在线看| 久久精品夜色噜噜亚洲a∨| 欧美激情在线一区二区三区| 亚洲欧美色一区| 视频一区二区中文字幕| 麻豆国产精品视频| 成人精品一区二区三区中文字幕| av亚洲精华国产精华精华| 天堂一区二区在线免费观看| 欧美视频一区二区三区在线观看| 欧美三级电影网| 日韩精品一区二区在线| 一区二区三区中文字幕电影 | 日韩影院在线观看| 激情丁香综合五月| 成人sese在线| 911精品国产一区二区在线| 久久在线观看免费| 亚洲欧美一区二区不卡| 日本v片在线高清不卡在线观看| 国产成人久久精品77777最新版本| 色综合中文字幕国产 | 久久综合成人精品亚洲另类欧美| 中文字幕一区二区三区在线播放| 肉色丝袜一区二区| 成人开心网精品视频| 5月丁香婷婷综合| 国产精品系列在线| 午夜精品一区在线观看| 国产成人午夜精品影院观看视频| 欧美中文字幕不卡| 国产亚洲精品aa午夜观看| 亚洲一区免费视频| 国产精品一级黄| 欧美卡1卡2卡| 亚洲婷婷综合久久一本伊一区| 免费高清不卡av| 日本福利一区二区| 久久一二三国产| 视频在线观看一区| 99精品1区2区| 久久亚洲二区三区| 日本三级韩国三级欧美三级| 91在线观看下载| 精品少妇一区二区三区日产乱码| 亚洲精品你懂的| 成人性色生活片免费看爆迷你毛片| 欧美卡1卡2卡| 亚洲第一成人在线| 色哟哟在线观看一区二区三区| 久久精品视频在线看| 热久久久久久久| 在线观看不卡视频| 亚洲欧洲韩国日本视频| 黑人巨大精品欧美一区| 欧美卡1卡2卡| 亚洲国产日韩a在线播放性色| 99久久综合色| 日本一区二区三区在线观看| 精彩视频一区二区三区| 91精品国产综合久久久蜜臀图片| 亚洲精品一二三| 色综合久久中文字幕| 中文文精品字幕一区二区| 精品亚洲成a人| 欧美一级黄色录像| 视频一区中文字幕国产| 欧美一a一片一级一片| 中文字幕字幕中文在线中不卡视频| 国产精品系列在线播放| 精品盗摄一区二区三区| 另类综合日韩欧美亚洲| 亚洲va韩国va欧美va精品 | 精品国产凹凸成av人网站| 日韩精品久久久久久| 欧美怡红院视频| 亚洲一二三四在线观看| 在线欧美日韩国产| 亚洲乱码中文字幕| 一道本成人在线| 日韩伦理免费电影| 91麻豆蜜桃一区二区三区| 亚洲视频中文字幕| 97久久久精品综合88久久| 日韩一区在线播放| 一本大道久久a久久精二百| 亚洲欧美日韩人成在线播放| 在线一区二区视频| 午夜国产不卡在线观看视频| 欧美电影一区二区| 捆绑调教一区二区三区| 日韩精品一区二区三区四区 | 欧美久久久久久久久| 午夜精品一区在线观看| 日韩欧美国产一区在线观看| 久久爱另类一区二区小说| 精品成人一区二区三区四区| 国产成人亚洲综合色影视| 国产精品色哟哟| 亚洲国产成人午夜在线一区| 成人午夜视频在线| 日韩美女啊v在线免费观看| 欧美视频一区二区三区在线观看 | 亚洲成人激情综合网| 欧美一级欧美一级在线播放| 精品无人区卡一卡二卡三乱码免费卡| 国产日韩欧美电影| 色婷婷av一区二区三区之一色屋| 香蕉久久夜色精品国产使用方法| 欧美va亚洲va| 9i看片成人免费高清| 天天做天天摸天天爽国产一区| 欧美一区二区精品| 国产69精品久久久久毛片| 亚洲人成在线播放网站岛国| 欧美高清性hdvideosex| 国产麻豆成人传媒免费观看| 一区二区三区四区精品在线视频| 欧美美女一区二区| 国产91精品精华液一区二区三区| 一区二区三区中文字幕精品精品| 日韩精品中文字幕一区 | 欧美一级久久久| 成人国产一区二区三区精品| 天天av天天翘天天综合网| 久久久蜜桃精品| 国产精品丝袜久久久久久app| 99re热这里只有精品视频| 亚洲一区二区精品3399| 日韩免费看的电影| 99国产精品久久久久久久久久 | 99v久久综合狠狠综合久久| 午夜精品久久久久久| 精品精品欲导航| 91天堂素人约啪| 久久se这里有精品| 亚洲欧美经典视频| 久久久国产综合精品女国产盗摄| 欧美性做爰猛烈叫床潮| 一本色道亚洲精品aⅴ| 日韩高清一区二区| 亚洲你懂的在线视频| 精品国产亚洲一区二区三区在线观看| heyzo一本久久综合| 精品中文字幕一区二区| 亚洲尤物视频在线| 国产精品网站导航| 精品国一区二区三区| 欧美丰满高潮xxxx喷水动漫| 91丨porny丨最新| 国产成人小视频| 麻豆精品一二三| 视频一区二区三区在线| 一区二区三区中文字幕在线观看| 中文字幕av资源一区| 久久综合九色综合欧美亚洲| 欧美日韩国产电影| 91网站最新地址| 天天影视网天天综合色在线播放 | 亚洲国产高清不卡| 日韩你懂的在线播放| 欧美日韩在线精品一区二区三区激情| 成人伦理片在线| 国产精品亚洲综合一区在线观看| 日本成人在线网站| 一区二区三区高清不卡| 亚洲区小说区图片区qvod| 国产精品视频你懂的| 久久久久久9999| 精品国产乱码久久久久久老虎 | 亚洲日本免费电影| 国产精品美女久久久久久久久| 久久精品一区二区三区四区| 26uuu国产电影一区二区| 日韩欧美国产综合| 日韩免费观看2025年上映的电影| 欧美男生操女生|