-
-
[求助]NtUserQueryWindow的参数问题
-
发表于: 2014-1-7 00:13 7032
-
QUERY_WINDOW_UNIQUE_PROCESS_ID这个CASE和QUERY_WINDOW_REAL_ID
有啥不一样
我看到的都是返回一个进程的ID
我用这个的时候返回全部都是0
有啥不一样
我看到的都是返回一个进程的ID
我用这个的时候返回全部都是0
DWORD APIENTRY NtUserQueryWindow(HWND hWnd, DWORD Index) { PWND pWnd; DWORD Result; DECLARE_RETURN(UINT); TRACE("Enter NtUserQueryWindow\n"); UserEnterShared(); if (!(pWnd = UserGetWindowObject(hWnd))) { RETURN( 0); } switch(Index) { case QUERY_WINDOW_UNIQUE_PROCESS_ID: Result = (DWORD)IntGetWndProcessId(pWnd); break; case QUERY_WINDOW_UNIQUE_THREAD_ID: Result = (DWORD)IntGetWndThreadId(pWnd); break; case QUERY_WINDOW_ACTIVE: Result = (DWORD)(pWnd->head.pti->MessageQueue->spwndActive ? UserHMGetHandle(pWnd->head.pti->MessageQueue->spwndActive) : 0); break; case QUERY_WINDOW_FOCUS: Result = (DWORD)(pWnd->head.pti->MessageQueue->spwndFocus ? UserHMGetHandle(pWnd->head.pti->MessageQueue->spwndFocus) : 0); break; case QUERY_WINDOW_ISHUNG: Result = (DWORD)MsqIsHung(pWnd->head.pti->MessageQueue); break; case QUERY_WINDOW_REAL_ID: Result = (DWORD)pWnd->head.pti->pEThread->Cid.UniqueProcess; break; case QUERY_WINDOW_FOREGROUND: Result = (pWnd->head.pti->MessageQueue == gpqForeground); break; default: Result = (DWORD)NULL; break; } RETURN( Result); CLEANUP: TRACE("Leave NtUserQueryWindow, ret=%i\n",_ret_); UserLeave(); END_CLEANUP; }
[培训]内核驱动高级班,冲击BAT一流互联网大厂工作,每周日13:00-18:00直播授课
赞赏
他的文章
- [讨论][求助]iOS不越狱的情况能否模拟点击其它app的控件? 10229
- [求助]IDA反编译一个XXTea算法实现 3401
- [求助]关于小米手机MIUI系统中Fid的溯源 4663
- [求助]Build.SERIAL动态修改 3865
- [求助]关于dns劫持的问题 3205
看原图
赞赏
雪币:
留言: