From 2a5fd78f1bcd3706a7f172668c35739aec3a28a2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Herm=C3=A8s=20B=C3=A9lusca-Ma=C3=AFto?= Date: Thu, 5 Oct 2023 21:32:26 +0200 Subject: [PATCH] [APPHELP_APITEST] Fix build, addendum to commit a8755711b --- modules/rostests/apitests/apphelp/apphelp_apitest.h | 4 ++-- modules/rostests/apitests/apphelp/data.c | 2 +- modules/rostests/apitests/apphelp/register.cpp | 5 ++--- 3 files changed, 5 insertions(+), 6 deletions(-) diff --git a/modules/rostests/apitests/apphelp/apphelp_apitest.h b/modules/rostests/apitests/apphelp/apphelp_apitest.h index 58cade256ab..5a9e9d470cc 100644 --- a/modules/rostests/apitests/apphelp/apphelp_apitest.h +++ b/modules/rostests/apitests/apphelp/apphelp_apitest.h @@ -21,9 +21,9 @@ void silence_debug_output(void); // Silence output if the environment var #define test_create_ne (winetest_set_location(__FILE__, __LINE__), 0) ? (void)0 : test_create_ne_imp /* register.cpp */ -BOOL IsUserAdmin(); +BOOL IsUserAdmin(VOID); -static DWORD g_WinVersion; +extern DWORD g_WinVersion; #define WINVER_ANY 0 #define WINVER_WINXP 0x0501 diff --git a/modules/rostests/apitests/apphelp/data.c b/modules/rostests/apitests/apphelp/data.c index dffad647572..dd8162626e2 100644 --- a/modules/rostests/apitests/apphelp/data.c +++ b/modules/rostests/apitests/apphelp/data.c @@ -792,7 +792,7 @@ void test_create_db_imp(const WCHAR* name, int win10) } } -static DWORD g_WinVersion; +DWORD g_WinVersion; DWORD get_host_winver(void) { if (!g_WinVersion) diff --git a/modules/rostests/apitests/apphelp/register.cpp b/modules/rostests/apitests/apphelp/register.cpp index 647ab6b4a9f..092d0221088 100644 --- a/modules/rostests/apitests/apphelp/register.cpp +++ b/modules/rostests/apitests/apphelp/register.cpp @@ -13,8 +13,6 @@ #include #include "wine/test.h" -#include "apphelp_apitest.h" - static const unsigned char rawDB[] = { /* Header: Major, Minor, 'sdbf' */ @@ -79,7 +77,8 @@ BOOL (WINAPI *pSdbRegisterDatabaseEx)(LPCWSTR pszDatabasePath, DWORD dwDatabaseT BOOL (WINAPI *pSdbUnregisterDatabase)(REFGUID pguidDB); -BOOL IsUserAdmin() +extern "C" +BOOL IsUserAdmin(VOID) { BOOL Result; SID_IDENTIFIER_AUTHORITY NtAuthority = { SECURITY_NT_AUTHORITY };