From: Sebastian Lackner sebastian@fds-team.de
Signed-off-by: Alistair Leslie-Hughes leslie_alistair@hotmail.com --- dlls/user32/winstation.c | 11 ++++++----- include/winuser.h | 2 ++ 2 files changed, 8 insertions(+), 5 deletions(-)
diff --git a/dlls/user32/winstation.c b/dlls/user32/winstation.c index 673917c..4f53b43 100644 --- a/dlls/user32/winstation.c +++ b/dlls/user32/winstation.c @@ -83,26 +83,26 @@ static HANDLE get_winstations_dir_handle(void) /*********************************************************************** * CreateWindowStationA (USER32.@) */ -HWINSTA WINAPI CreateWindowStationA( LPCSTR name, DWORD reserved, ACCESS_MASK access, +HWINSTA WINAPI CreateWindowStationA( LPCSTR name, DWORD flags, ACCESS_MASK access, LPSECURITY_ATTRIBUTES sa ) { WCHAR buffer[MAX_PATH];
- if (!name) return CreateWindowStationW( NULL, reserved, access, sa ); + if (!name) return CreateWindowStationW( NULL, flags, access, sa );
if (!MultiByteToWideChar( CP_ACP, 0, name, -1, buffer, MAX_PATH )) { SetLastError( ERROR_FILENAME_EXCED_RANGE ); return 0; } - return CreateWindowStationW( buffer, reserved, access, sa ); + return CreateWindowStationW( buffer, flags, access, sa ); }
/*********************************************************************** * CreateWindowStationW (USER32.@) */ -HWINSTA WINAPI CreateWindowStationW( LPCWSTR name, DWORD reserved, ACCESS_MASK access, +HWINSTA WINAPI CreateWindowStationW( LPCWSTR name, DWORD flags, ACCESS_MASK access, LPSECURITY_ATTRIBUTES sa ) { HANDLE ret; @@ -117,7 +117,8 @@ HWINSTA WINAPI CreateWindowStationW( LPCWSTR name, DWORD reserved, ACCESS_MASK a { req->flags = 0; req->access = access; - req->attributes = OBJ_CASE_INSENSITIVE | OBJ_OPENIF | + req->attributes = OBJ_CASE_INSENSITIVE | + ((flags & CWF_CREATE_ONLY) ? 0 : OBJ_OPENIF) | ((sa && sa->bInheritHandle) ? OBJ_INHERIT : 0); req->rootdir = wine_server_obj_handle( get_winstations_dir_handle() ); wine_server_add_data( req, name, len * sizeof(WCHAR) ); diff --git a/include/winuser.h b/include/winuser.h index 3cffaa1..28b9b1f 100644 --- a/include/winuser.h +++ b/include/winuser.h @@ -101,6 +101,8 @@ typedef void* HPOWERNOTIFY; #define WSF_VISIBLE 1 #define DF_ALLOWOTHERACCOUNTHOOK 1
+#define CWF_CREATE_ONLY 0x01 + typedef struct tagUSEROBJECTFLAGS { BOOL fInherit; BOOL fReserved;
Hi,
While running your changed tests, I think I found new failures. Being a bot and all I'm not very good at pattern recognition, so I might be wrong, but could you please double-check?
Full results can be found at: https://testbot.winehq.org/JobDetails.pl?Key=50638
Your paranoid android.
=== debian9 (32 bit report) ===
user32: msg.c:8713: Test failed: WaitForSingleObject failed 102 msg.c:8719: Test failed: destroy child on thread exit: 0: the msg 0x0082 was expected, but got msg 0x000f instead msg.c:8719: Test failed: destroy child on thread exit: 1: the msg 0x000f was expected, but got msg 0x0014 instead msg.c:8719: Test failed: destroy child on thread exit: 2: the msg sequence is not complete: expected 0014 - actual 0000
=== debian9 (32 bit Chinese:China report) ===
user32: msg.c:8713: Test failed: WaitForSingleObject failed 102 msg.c:8719: Test failed: destroy child on thread exit: 0: the msg 0x0082 was expected, but got msg 0x000f instead msg.c:8719: Test failed: destroy child on thread exit: 1: the msg 0x000f was expected, but got msg 0x0014 instead msg.c:8719: Test failed: destroy child on thread exit: 2: the msg sequence is not complete: expected 0014 - actual 0000