Thank you for looking at the MR! Re: 6/6 - the desktop needs to be in the processes session. Checking for NULL after inheriting the winstation won't change if the parent process is a valid winstation. But I agree that this should probably come as a last fallback; if no winstation is found or nothing could be intherited or the inherited winstation lives in a different session, then we should reset to the default. Maybe it is a wise idea to test what windows does here, but I am still not entirely sure how to code such a test within the WINE conformance tests - WTSQueryUserToken is basically only callable from within a service context, and I still understand winetest way to little to implement this into the wtsapi tests. Regarding the switch, yeah, I thought that this conveys a bit clearer than an if/else that the two cases are session 0 and 1 (with 1 adopting the default). But I can surely change that and explain the case in a comment. Re: 1-5/6: I'll implement this in the next iteration. Sorry for the noise in review; I am still getting acquainted to the WINE code base and "how things are usually done". Thank you for taking the time to point out the little things! -- https://gitlab.winehq.org/wine/wine/-/merge_requests/9843#note_127442