diff --git a/reactos/dll/win32/user32/include/user32.h b/reactos/dll/win32/user32/include/user32.h index e54eee4adde..5cbd4e2d439 100644 --- a/reactos/dll/win32/user32/include/user32.h +++ b/reactos/dll/win32/user32/include/user32.h @@ -100,7 +100,7 @@ IsThreadHooked(PCLIENTINFO pci) static __inline PDESKTOPINFO GetThreadDesktopInfo(VOID) { - PW32THREADINFO ti; + PTHREADINFO ti; PDESKTOPINFO di = NULL; ti = GetW32ThreadInfo(); diff --git a/reactos/dll/win32/user32/include/user32p.h b/reactos/dll/win32/user32/include/user32p.h index b27e39036d9..2595589593e 100644 --- a/reactos/dll/win32/user32/include/user32p.h +++ b/reactos/dll/win32/user32/include/user32p.h @@ -199,7 +199,7 @@ typedef struct _USER_HANDLE_ENTRY union { PVOID pi; - PW32THREADINFO pti; // pointer to Win32ThreadInfo + PTHREADINFO pti; // pointer to Win32ThreadInfo PPROCESSINFO ppi; // pointer to W32ProcessInfo }; unsigned short type; /* object type (0 if free) */ diff --git a/reactos/dll/win32/user32/misc/dllmain.c b/reactos/dll/win32/user32/misc/dllmain.c index 8ac270190db..01f5153fb19 100644 --- a/reactos/dll/win32/user32/misc/dllmain.c +++ b/reactos/dll/win32/user32/misc/dllmain.c @@ -335,7 +335,7 @@ GetConnected(VOID) USERCONNECT UserCon; // ERR("GetConnected\n"); - if ((PW32THREADINFO)NtCurrentTeb()->Win32ThreadInfo == NULL) + if ((PTHREADINFO)NtCurrentTeb()->Win32ThreadInfo == NULL) NtUserGetThreadState(THREADSTATE_GETTHREADINFO); if (gpsi && g_ppi) return; diff --git a/reactos/dll/win32/user32/misc/misc.c b/reactos/dll/win32/user32/misc/misc.c index 9f5938637f5..3e664b23276 100644 --- a/reactos/dll/win32/user32/misc/misc.c +++ b/reactos/dll/win32/user32/misc/misc.c @@ -104,17 +104,17 @@ UpdatePerUserSystemParameters( return NtUserUpdatePerUserSystemParameters(dwReserved, bEnable); } -PW32THREADINFO +PTHREADINFO GetW32ThreadInfo(VOID) { - PW32THREADINFO ti; + PTHREADINFO ti; - ti = (PW32THREADINFO)NtCurrentTeb()->Win32ThreadInfo; + ti = (PTHREADINFO)NtCurrentTeb()->Win32ThreadInfo; if (ti == NULL) { - /* create the W32THREADINFO structure */ + /* create the THREADINFO structure */ NtUserGetThreadState(THREADSTATE_GETTHREADINFO); - ti = (PW32THREADINFO)NtCurrentTeb()->Win32ThreadInfo; + ti = (PTHREADINFO)NtCurrentTeb()->Win32ThreadInfo; } return ti; @@ -250,13 +250,13 @@ WINAPI IsGUIThread( BOOL bConvert) { - PW32THREADINFO ti = (PW32THREADINFO)NtCurrentTeb()->Win32ThreadInfo; + PTHREADINFO ti = (PTHREADINFO)NtCurrentTeb()->Win32ThreadInfo; if (ti == NULL) { if(bConvert) { NtUserGetThreadState(THREADSTATE_GETTHREADINFO); - if ((PW32THREADINFO)NtCurrentTeb()->Win32ThreadInfo) return TRUE; + if ((PTHREADINFO)NtCurrentTeb()->Win32ThreadInfo) return TRUE; else SetLastError(ERROR_NOT_ENOUGH_MEMORY); } @@ -270,7 +270,7 @@ BOOL FASTCALL TestWindowProcess(PWND Wnd) { - if (Wnd->head.pti == (PW32THREADINFO)NtCurrentTeb()->Win32ThreadInfo) + if (Wnd->head.pti == (PTHREADINFO)NtCurrentTeb()->Win32ThreadInfo) return TRUE; else return (NtUserQueryWindow(Wnd->head.h, QUERY_WINDOW_UNIQUE_PROCESS_ID) == diff --git a/reactos/dll/win32/user32/windows/hook.c b/reactos/dll/win32/user32/windows/hook.c index 73b394ba7d1..863383cd195 100644 --- a/reactos/dll/win32/user32/windows/hook.c +++ b/reactos/dll/win32/user32/windows/hook.c @@ -369,7 +369,7 @@ WINAPI IsWinEventHookInstalled( DWORD event) { - if ((PW32THREADINFO)NtCurrentTeb()->Win32ThreadInfo) + if ((PTHREADINFO)NtCurrentTeb()->Win32ThreadInfo) { return (gpsi->dwInstalledEventHooks & GetMaskFromEvent(event)) != 0; } diff --git a/reactos/dll/win32/user32/windows/message.c b/reactos/dll/win32/user32/windows/message.c index 57bf25882b0..54f7d38a86b 100644 --- a/reactos/dll/win32/user32/windows/message.c +++ b/reactos/dll/win32/user32/windows/message.c @@ -1333,7 +1333,7 @@ DispatchMessageA(CONST MSG *lpmsg) if (lpmsg->hwnd != NULL) { Wnd = ValidateHwnd(lpmsg->hwnd); - if (!Wnd || SharedPtrToUser(Wnd->head.pti) != GetW32ThreadInfo()) + if (!Wnd || Wnd->head.pti != GetW32ThreadInfo()) return 0; } else @@ -1394,7 +1394,7 @@ DispatchMessageW(CONST MSG *lpmsg) if (lpmsg->hwnd != NULL) { Wnd = ValidateHwnd(lpmsg->hwnd); - if (!Wnd || SharedPtrToUser(Wnd->head.pti) != GetW32ThreadInfo()) + if (!Wnd || Wnd->head.pti != GetW32ThreadInfo()) return 0; } else @@ -1791,10 +1791,10 @@ SendMessageW(HWND Wnd, if (Wnd != HWND_BROADCAST && (Msg < WM_DDE_FIRST || Msg > WM_DDE_LAST)) { PWND Window; - PW32THREADINFO ti = GetW32ThreadInfo(); + PTHREADINFO ti = GetW32ThreadInfo(); Window = ValidateHwnd(Wnd); - if (Window != NULL && SharedPtrToUser(Window->head.pti) == ti && !IsThreadHooked(GetWin32ClientInfo())) + if (Window != NULL && Window->head.pti == ti && !IsThreadHooked(GetWin32ClientInfo())) { /* NOTE: We can directly send messages to the window procedure if *all* the following conditions are met: @@ -1855,10 +1855,10 @@ SendMessageA(HWND Wnd, UINT Msg, WPARAM wParam, LPARAM lParam) if (Wnd != HWND_BROADCAST && (Msg < WM_DDE_FIRST || Msg > WM_DDE_LAST)) { PWND Window; - PW32THREADINFO ti = GetW32ThreadInfo(); + PTHREADINFO ti = GetW32ThreadInfo(); Window = ValidateHwnd(Wnd); - if (Window != NULL && SharedPtrToUser(Window->head.pti) == ti && !IsThreadHooked(GetWin32ClientInfo())) + if (Window != NULL && Window->head.pti == ti && !IsThreadHooked(GetWin32ClientInfo())) { /* NOTE: We can directly send messages to the window procedure if *all* the following conditions are met: diff --git a/reactos/dll/win32/user32/windows/window.c b/reactos/dll/win32/user32/windows/window.c index f76aa2ced84..c20cce8a0c9 100644 --- a/reactos/dll/win32/user32/windows/window.c +++ b/reactos/dll/win32/user32/windows/window.c @@ -1316,12 +1316,12 @@ GetWindowThreadProcessId(HWND hWnd, LPDWORD lpdwProcessId) { DWORD Ret = 0; - PW32THREADINFO ti; + PTHREADINFO ti; PWND pWnd = ValidateHwnd(hWnd); if (!pWnd) return Ret; - ti = SharedPtrToUser(pWnd->head.pti); + ti = pWnd->head.pti; if (ti) { diff --git a/reactos/include/reactos/win32k/ntuser.h b/reactos/include/reactos/win32k/ntuser.h index 738b1547f73..9bc679b4da1 100644 --- a/reactos/include/reactos/win32k/ntuser.h +++ b/reactos/include/reactos/win32k/ntuser.h @@ -2,6 +2,7 @@ #define __WIN32K_NTUSER_H typedef struct _PROCESSINFO *PPROCESSINFO; +typedef struct _THREADINFO *PTHREADINFO; struct _DESKTOP; struct _WND; @@ -72,13 +73,6 @@ typedef struct _CLIENTTHREADINFO DWORD dwcPumpHook; } CLIENTTHREADINFO, *PCLIENTTHREADINFO; -typedef struct _W32THREADINFO -{ - PPROCESSINFO ppi; /* [KERNEL] */ - PDESKTOPINFO pDeskInfo; - ULONG fsHooks; -} W32THREADINFO, *PW32THREADINFO; - typedef struct _HEAD { HANDLE h; @@ -88,7 +82,7 @@ typedef struct _HEAD typedef struct _THROBJHEAD { HEAD; - PW32THREADINFO pti; + PTHREADINFO pti; } THROBJHEAD, *PTHROBJHEAD; typedef struct _THRDESKHEAD @@ -701,7 +695,7 @@ typedef struct _BROADCASTPARM LUID luid; } BROADCASTPARM, *PBROADCASTPARM; -PW32THREADINFO GetW32ThreadInfo(VOID); +PTHREADINFO GetW32ThreadInfo(VOID); PPROCESSINFO GetW32ProcessInfo(VOID); typedef struct _WNDMSG diff --git a/reactos/subsystems/win32/win32k/include/object.h b/reactos/subsystems/win32/win32k/include/object.h index f6b36468416..76af581542b 100644 --- a/reactos/subsystems/win32/win32k/include/object.h +++ b/reactos/subsystems/win32/win32k/include/object.h @@ -22,7 +22,7 @@ typedef struct _USER_HANDLE_ENTRY union { PVOID pi; - PW32THREADINFO pti; // pointer to Win32ThreadInfo + PTHREADINFO pti; // pointer to Win32ThreadInfo PPROCESSINFO ppi; // pointer to W32ProcessInfo }; unsigned short type; /* object type (0 if free) */ diff --git a/reactos/subsystems/win32/win32k/include/win32.h b/reactos/subsystems/win32/win32k/include/win32.h index c4eb8636e7f..1e8706a73e0 100644 --- a/reactos/subsystems/win32/win32k/include/win32.h +++ b/reactos/subsystems/win32/win32k/include/win32.h @@ -88,8 +88,7 @@ typedef struct _THREADINFO LIST_ENTRY W32CallbackListHead; BOOLEAN IsExiting; SINGLE_LIST_ENTRY ReferencesList; - PW32THREADINFO ThreadInfo; -} THREADINFO, *PTHREADINFO; +} THREADINFO; #include diff --git a/reactos/subsystems/win32/win32k/include/window.h b/reactos/subsystems/win32/win32k/include/window.h index 16537c1448b..46deb3f19ca 100644 --- a/reactos/subsystems/win32/win32k/include/window.h +++ b/reactos/subsystems/win32/win32k/include/window.h @@ -26,7 +26,7 @@ typedef struct _WINDOW_OBJECT PWND Wnd; /* Pointer to the thread information */ - PW32THREADINFO ti; + PTHREADINFO ti; /* Pointer to the desktop */ PDESKTOPINFO Desktop; /* system menu handle. */ diff --git a/reactos/subsystems/win32/win32k/main/dllmain.c b/reactos/subsystems/win32/win32k/main/dllmain.c index a5436a076ee..944b4f55677 100644 --- a/reactos/subsystems/win32/win32k/main/dllmain.c +++ b/reactos/subsystems/win32/win32k/main/dllmain.c @@ -306,12 +306,6 @@ Win32kThreadCallback(struct _ETHREAD *Thread, IntSetThreadDesktop(NULL, TRUE); - if (Win32Thread->ThreadInfo != NULL) - { - UserHeapFree(Win32Thread->ThreadInfo); - Win32Thread->ThreadInfo = NULL; - } - PsSetThreadWin32Thread(Thread, NULL); } diff --git a/reactos/subsystems/win32/win32k/ntuser/class.c b/reactos/subsystems/win32/win32k/ntuser/class.c index 76b1e6959ef..f27d56c1e09 100644 --- a/reactos/subsystems/win32/win32k/ntuser/class.c +++ b/reactos/subsystems/win32/win32k/ntuser/class.c @@ -1171,7 +1171,6 @@ UserRegisterClass(IN CONST WNDCLASSEXW* lpwcx, IN DWORD dwFlags) { PTHREADINFO pti; - PW32THREADINFO ti; PPROCESSINFO pi; PCLS Class; RTL_ATOM ClassAtom; @@ -1179,15 +1178,14 @@ UserRegisterClass(IN CONST WNDCLASSEXW* lpwcx, /* NOTE: Accessing the buffers in ClassName and MenuName may raise exceptions! */ - pti = PsGetCurrentThreadWin32Thread(); - ti = GetW32ThreadInfo(); - if (ti == NULL || !RegisteredSysClasses) + pti = GetW32ThreadInfo(); + if (pti == NULL || !RegisteredSysClasses) { SetLastWin32Error(ERROR_NOT_ENOUGH_MEMORY); return (RTL_ATOM)0; } - pi = ti->ppi; + pi = pti->ppi; /* try to find a previously registered class */ ClassAtom = IntGetClassAtom(ClassName, diff --git a/reactos/subsystems/win32/win32k/ntuser/desktop.c b/reactos/subsystems/win32/win32k/ntuser/desktop.c index 2bcfdcd4c1d..14f979b16a6 100644 --- a/reactos/subsystems/win32/win32k/ntuser/desktop.c +++ b/reactos/subsystems/win32/win32k/ntuser/desktop.c @@ -1846,7 +1846,7 @@ CLEANUP: static NTSTATUS IntUnmapDesktopView(IN PDESKTOP DesktopObject) { - PW32THREADINFO ti; + PTHREADINFO ti; PPROCESSINFO CurrentWin32Process; PW32HEAP_USER_MAPPING HeapMapping, *PrevLink; NTSTATUS Status = STATUS_SUCCESS; @@ -1883,10 +1883,6 @@ IntUnmapDesktopView(IN PDESKTOP DesktopObject) ti = GetW32ThreadInfo(); if (ti != NULL) { - if (ti->pDeskInfo == DesktopObject->DesktopInfo) - { - ti->pDeskInfo = NULL; - } GetWin32ClientInfo()->pDeskInfo = NULL; } GetWin32ClientInfo()->ulClientDelta = 0; @@ -1897,7 +1893,7 @@ IntUnmapDesktopView(IN PDESKTOP DesktopObject) static NTSTATUS IntMapDesktopView(IN PDESKTOP DesktopObject) { - PW32THREADINFO ti; + PTHREADINFO ti; PPROCESSINFO CurrentWin32Process; PW32HEAP_USER_MAPPING HeapMapping, *PrevLink; PVOID UserBase = NULL; @@ -1965,11 +1961,11 @@ IntMapDesktopView(IN PDESKTOP DesktopObject) GetWin32ClientInfo()->ulClientDelta = DesktopHeapGetUserDelta(); if (ti != NULL) { - if (ti->pDeskInfo == NULL) + if (GetWin32ClientInfo()->pDeskInfo == NULL) { - ti->pDeskInfo = DesktopObject->DesktopInfo; GetWin32ClientInfo()->pDeskInfo = - (PVOID)((ULONG_PTR)ti->pDeskInfo - GetWin32ClientInfo()->ulClientDelta); + (PVOID)((ULONG_PTR)DesktopObject->DesktopInfo - + GetWin32ClientInfo()->ulClientDelta); } } @@ -2012,15 +2008,6 @@ IntSetThreadDesktop(IN PDESKTOP DesktopObject, } } - if (W32Thread->Desktop == NULL) - { - PW32THREADINFO ti = GetW32ThreadInfo(); - if (ti != NULL) - { - ti->pDeskInfo = NULL; - } - } - /* Hack for system threads */ if (NtCurrentTeb()) { diff --git a/reactos/subsystems/win32/win32k/ntuser/hook.c b/reactos/subsystems/win32/win32k/ntuser/hook.c index 6c476489ae5..8ee3c655b51 100644 --- a/reactos/subsystems/win32/win32k/ntuser/hook.c +++ b/reactos/subsystems/win32/win32k/ntuser/hook.c @@ -117,9 +117,6 @@ IntAddHook(PETHREAD Thread, int HookId, BOOLEAN Global, PWINSTATION_OBJECT WinSt W32Thread->fsHooks |= HOOKID_TO_FLAG(HookId); GetWin32ClientInfo()->fsHooks = W32Thread->fsHooks; - - if (W32Thread->ThreadInfo != NULL) - W32Thread->ThreadInfo->fsHooks = W32Thread->fsHooks; } RtlInitUnicodeString(&Hook->ModuleName, NULL); @@ -243,9 +240,6 @@ IntRemoveHook(PHOOK Hook, PWINSTATION_OBJECT WinStaObj, BOOL TableAlreadyLocked) GetWin32ClientInfo()->fsHooks = W32Thread->fsHooks; - if (W32Thread->ThreadInfo != NULL) - W32Thread->ThreadInfo->fsHooks = W32Thread->fsHooks; - if (0 != Table->Counts[HOOKID_TO_INDEX(Hook->HookId)]) { Hook->Proc = NULL; /* chain is in use, just mark it and return */ diff --git a/reactos/subsystems/win32/win32k/ntuser/message.c b/reactos/subsystems/win32/win32k/ntuser/message.c index 6cba6ae58e6..367bd9db81b 100644 --- a/reactos/subsystems/win32/win32k/ntuser/message.c +++ b/reactos/subsystems/win32/win32k/ntuser/message.c @@ -1,21 +1,3 @@ -/* - * ReactOS W32 Subsystem - * Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003 ReactOS Team - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. - */ /* * COPYRIGHT: See COPYING in the top level directory * PROJECT: ReactOS kernel @@ -307,7 +289,7 @@ IntCallWndProc { BOOL SameThread = FALSE; - if (Window->ti == ((PTHREADINFO)PsGetCurrentThreadWin32Thread())->ThreadInfo) + if (Window->ti == ((PTHREADINFO)PsGetCurrentThreadWin32Thread())) SameThread = TRUE; if ((!SameThread && (Window->ti->fsHooks & HOOKID_TO_FLAG(WH_CALLWNDPROC))) || @@ -329,7 +311,7 @@ IntCallWndProcRet { BOOL SameThread = FALSE; - if (Window->ti == ((PTHREADINFO)PsGetCurrentThreadWin32Thread())->ThreadInfo) + if (Window->ti == ((PTHREADINFO)PsGetCurrentThreadWin32Thread())) SameThread = TRUE; if ((!SameThread && (Window->ti->fsHooks & HOOKID_TO_FLAG(WH_CALLWNDPROCRET))) || diff --git a/reactos/subsystems/win32/win32k/ntuser/misc.c b/reactos/subsystems/win32/win32k/ntuser/misc.c index 4a4020fe5f7..3deaaf2a01e 100644 --- a/reactos/subsystems/win32/win32k/ntuser/misc.c +++ b/reactos/subsystems/win32/win32k/ntuser/misc.c @@ -451,11 +451,10 @@ GetW32ProcessInfo(VOID) return (PPROCESSINFO)PsGetCurrentProcessWin32Process(); } -PW32THREADINFO +PTHREADINFO GetW32ThreadInfo(VOID) { PTEB Teb; - PW32THREADINFO ti; PPROCESSINFO ppi; PCLIENTINFO pci; PTHREADINFO pti = PsGetCurrentThreadWin32Thread(); @@ -465,67 +464,49 @@ GetW32ThreadInfo(VOID) /* FIXME - temporary hack for system threads... */ return NULL; } + /* initialize it */ + pti->ppi = ppi = GetW32ProcessInfo(); - /* allocate a THREADINFO structure if neccessary */ - if (pti->ThreadInfo == NULL) + pti->pcti = &pti->cti; // FIXME Need to set it in desktop.c! + + if (pti->Desktop != NULL) { - ti = UserHeapAlloc(sizeof(W32THREADINFO)); - if (ti != NULL) + pti->pDeskInfo = pti->Desktop->DesktopInfo; + } + else + { + pti->pDeskInfo = NULL; + } + /* update the TEB */ + Teb = NtCurrentTeb(); + pci = GetWin32ClientInfo(); + pti->pClientInfo = pci; + _SEH2_TRY + { + ProbeForWrite( Teb, + sizeof(TEB), + sizeof(ULONG)); + + Teb->Win32ThreadInfo = (PW32THREAD) pti; + + pci->pClientThreadInfo = NULL; // FIXME Need to set it in desktop.c! + pci->ppi = ppi; + pci->fsHooks = pti->fsHooks; + /* CI may not have been initialized. */ + if (!pci->pDeskInfo && pti->pDeskInfo) { - RtlZeroMemory(ti, - sizeof(W32THREADINFO)); + if (!pci->ulClientDelta) pci->ulClientDelta = DesktopHeapGetUserDelta(); - /* initialize it */ - ti->ppi = ppi = GetW32ProcessInfo(); - ti->fsHooks = pti->fsHooks; - pti->pcti = &pti->cti; // FIXME Need to set it in desktop.c! - if (pti->Desktop != NULL) - { - pti->pDeskInfo = ti->pDeskInfo = pti->Desktop->DesktopInfo; - } - else - { - pti->pDeskInfo = ti->pDeskInfo = NULL; - } - - pti->ThreadInfo = ti; - /* update the TEB */ - Teb = NtCurrentTeb(); - pci = GetWin32ClientInfo(); - pti->pClientInfo = pci; - _SEH2_TRY - { - ProbeForWrite(Teb, - sizeof(TEB), - sizeof(ULONG)); - - Teb->Win32ThreadInfo = UserHeapAddressToUser(pti->ThreadInfo); - - pci->pClientThreadInfo = NULL; // FIXME Need to set it in desktop.c! - pci->ppi = ppi; - pci->fsHooks = pti->fsHooks; - /* CI may not have been initialized. */ - if (!pci->pDeskInfo && pti->pDeskInfo) - { - if (!pci->ulClientDelta) pci->ulClientDelta = DesktopHeapGetUserDelta(); - - pci->pDeskInfo = - (PVOID)((ULONG_PTR)pti->pDeskInfo - pci->ulClientDelta); - } - } - _SEH2_EXCEPT(EXCEPTION_EXECUTE_HANDLER) - { - SetLastNtError(_SEH2_GetExceptionCode()); - } - _SEH2_END; - } - else - { - SetLastWin32Error(ERROR_NOT_ENOUGH_MEMORY); + pci->pDeskInfo = (PVOID)((ULONG_PTR)pti->pDeskInfo - pci->ulClientDelta); } } + _SEH2_EXCEPT(EXCEPTION_EXECUTE_HANDLER) + { + SetLastNtError(_SEH2_GetExceptionCode()); + } + _SEH2_END; - return pti->ThreadInfo; + return pti; } diff --git a/reactos/subsystems/win32/win32k/ntuser/simplecall.c b/reactos/subsystems/win32/win32k/ntuser/simplecall.c index 2a4c5a9f3e2..f9fb61b6adb 100644 --- a/reactos/subsystems/win32/win32k/ntuser/simplecall.c +++ b/reactos/subsystems/win32/win32k/ntuser/simplecall.c @@ -164,7 +164,7 @@ NtUserCallOneParam( case ONEPARAM_ROUTINE_GETDESKTOPMAPPING: { - PW32THREADINFO ti; + PTHREADINFO ti; ti = GetW32ThreadInfo(); if (ti != NULL) { diff --git a/reactos/subsystems/win32/win32k/ntuser/timer.c b/reactos/subsystems/win32/win32k/ntuser/timer.c index 69966ad1753..c2a3c2206ee 100644 --- a/reactos/subsystems/win32/win32k/ntuser/timer.c +++ b/reactos/subsystems/win32/win32k/ntuser/timer.c @@ -1,21 +1,3 @@ -/* - * ReactOS W32 Subsystem - * Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003 ReactOS Team - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. - */ /* * COPYRIGHT: See COPYING in the top level directory * PROJECT: ReactOS kernel @@ -162,7 +144,8 @@ ValidateTimerCallback(PTHREADINFO pti, { if ( (lParam == (LPARAM)pTmr->pfn) && (pTmr->flags & (TMRF_SYSTEM|TMRF_RIT)) && - (pTmr->pti->ThreadInfo->ppi == pti->ThreadInfo->ppi) ) +// (pTmr->head.pti->ppi == pti->ppi) ) + (pTmr->pti->ppi == pti->ppi) ) break; pTmr = (PTIMER)pTmr->ptmrList.Flink; diff --git a/reactos/subsystems/win32/win32k/ntuser/window.c b/reactos/subsystems/win32/win32k/ntuser/window.c index ba1c33ad73e..2250b7d58ac 100644 --- a/reactos/subsystems/win32/win32k/ntuser/window.c +++ b/reactos/subsystems/win32/win32k/ntuser/window.c @@ -103,7 +103,7 @@ PWINDOW_OBJECT FASTCALL IntGetWindowObject(HWND hWnd) /* temp hack */ PWINDOW_OBJECT FASTCALL UserGetWindowObject(HWND hWnd) { - PW32THREADINFO ti; + PTHREADINFO ti; PWINDOW_OBJECT Window; if (PsGetCurrentProcess() != PsInitialSystemProcess) @@ -314,7 +314,7 @@ static void IntSendDestroyMsg(HWND hWnd) } static VOID -UserFreeWindowInfo(PW32THREADINFO ti, PWINDOW_OBJECT WindowObject) +UserFreeWindowInfo(PTHREADINFO ti, PWINDOW_OBJECT WindowObject) { PCLIENTINFO ClientInfo = GetWin32ClientInfo(); PWND Wnd = WindowObject->Wnd; @@ -1551,7 +1551,7 @@ co_IntCreateWindowEx(DWORD dwExStyle, HWND hWnd; POINT Pos; SIZE Size; - PW32THREADINFO ti = NULL; + PTHREADINFO ti = NULL; #if 0 POINT MaxSize, MaxPos, MinTrack, MaxTrack; @@ -3311,7 +3311,7 @@ NtUserSetShellWindowEx(HWND hwndShell, HWND hwndListView) DECLARE_RETURN(BOOL); USER_REFERENCE_ENTRY Ref; NTSTATUS Status; - PW32THREADINFO ti; + PTHREADINFO ti; DPRINT("Enter NtUserSetShellWindowEx\n"); UserEnterExclusive();