Commit graph

8 commits

Author SHA1 Message Date
Hermès Bélusca-Maïto a8e7defb01
[WIN32SS:USER] Some minimal work and fixes concerning message queues timeouts.
CORE-15147

- Rename CLIENTTHREADINFO::tickLastMsgChecked into timeLastRead as
  documented in https://reactos.org/wiki/Techwiki:Win32k/CLIENTTHREADINFO .
  This is the last time the message queue was read.

- This is the structure member one must compare against the current tick
  count timestamp in order to heuristically determine whether a message
  queue thread is hung!! Fix MsqIsHung() in accordance, add extra debug
  logging in order to help us determining which of our code present
  regular GUI hangs, and add as well an extra "TimeOut" parameter so as
  not to hardcode a fixed value within that function but instead
  allowing its caller to specify possible different values.

- THREADINFO::timeLast is on the contrary the last message time stamp,
  and will definitively differ from CLIENTTHREADINFO::timeLastRead .
  It should only be used for information purposes!

- Accordingly, in NtUserGetThreadState()::THREADSTATE_UPTIMELASTREAD
  and in InitThreadCallback(), only (re-)initialize the timeLastRead
  member of the CLIENTTHREADINFO structure of the THREADINFO of interest.

- In co_IntPeekMessage(), update more often the timeLastRead timestamp
  whenever the current message queue has been read (but NOT timeLast!!
  That one will be updated ONLY WHEN a message is found!).

- In co_IntSendMessageTimeoutSingle() first check whether the window to
  which we send the message is being destroyed, before checking for
  queue hangs etc. Collapse the logic checks for queue hang and increase
  the hang timeout check to 4 times MSQ_HUNG (== 4 * 5 seconds) and
  display a debug trace.
2019-12-29 16:14:15 +01:00
Giannis Adamopoulos 1a8d9f12d6 [NTUSER] Implement creating the system threads
- Add UserCreateSystemThread function that will signal csrss to create a new system thread.
- NtUserCreateWindowStation: Create the raw input thread and the desktop thread when the IO window station gets created.
- IntMakeHungWindowGhosted: Create the ghost system thread that will own all ghost windows.
- Let the raw input thread manage the window station of csrss.

[USERSRV] Remove system threads creating hack
- Implement SrvCreateSystemThreads
- Don't create the system threads in UserServerDllInitialization.
2018-12-19 16:13:18 +02:00
Katayama Hirofumi MZ aa04a0a6d3
[WIN32SS] Replace ASSERT(FALSE); in IntGhostWindowFromHungWindow (#1116)
CORE-11944
2018-12-12 08:03:49 +09:00
Katayama Hirofumi MZ f469acacec
[WIN32SS][USER32] Add Ghost codes (retrial of #1100) (#1112)
CORE-11944
2018-12-11 12:30:59 +09:00
Katayama Hirofumi MZ 99b055a506
Revert "[WIN32SS][USER32] Add codes for Ghost Window (#1100)" (#1110)
This reverts commit 1adefd180c. ReactOS wouldn't startup.
2018-12-11 11:30:00 +09:00
Katayama Hirofumi MZ 1adefd180c
[WIN32SS][USER32] Add codes for Ghost Window (#1100)
CORE-11944
2018-12-11 10:48:23 +09:00
Pierre Schweitzer 958ae44599
[WIN32SS] Shhhhh! 2018-12-09 22:00:53 +01:00
Katayama Hirofumi MZ b09487fb44
[WIN32SS] Add IntGoGhost function (stub) (#1081)
CORE-11944
2018-12-01 20:59:07 +09:00