1. 16 Feb, 2021 1 commit
    • Rémi Bernon's avatar
      plugplay: Broadcast WM_DEVICECHANGE message asynchronously. · f5ca0601
      Rémi Bernon authored
      It may otherwise trigger a nasty race condition, where:
      
      1) For explorer.exe to register the CLSID_ShellWindows classes, it
         needs RpcSS service to be started,
      
      2) services.exe may start WinePlugPlay service group first, waiting for
         its startup to complete,
      
      3) during startup and early device enumeration, hidclass.sys may call
         IoSetDeviceInterfaceState, which calls plugplay_send_event [1],
      
      4) plugplay_send_event tries to broadcast a WM_DEVICECHANGE message with
         BSF_QUERY, waiting for the individual threads to reply,
      
      5) which times-out because window threads are waiting on explorer.exe
         to create its desktop window and reply to the WM_NULL SendMessage.
      
      This happens more likely as there is threads with message queues
      being started, each waiting on the desktop window to reply. Usually
      explorer.exe is able to reply to some messages with the implicit
      message processing while creating its window, but not all of them.
      
      [1] Not completely sure how, it looks like some RPC too, but before
          RpcSs is started?
      Signed-off-by: 's avatarRémi Bernon <rbernon@codeweavers.com>
      Signed-off-by: 's avatarAlexandre Julliard <julliard@winehq.org>
      f5ca0601
  2. 04 Dec, 2020 1 commit
  3. 12 Oct, 2020 1 commit
  4. 06 May, 2020 3 commits
  5. 17 Oct, 2019 1 commit
  6. 24 Apr, 2019 1 commit
  7. 02 Jan, 2014 1 commit
  8. 23 Jan, 2012 1 commit
  9. 20 Jan, 2012 1 commit
  10. 31 Jan, 2011 1 commit