Commit 46dfbf89 authored by Zebediah Figura's avatar Zebediah Figura Committed by Alexandre Julliard

advapi32: GetNamedSecurityInfo() takes a const name argument.

At least in the Windows 10 SDK.
parent df75c9ed
...@@ -185,7 +185,7 @@ static inline DWORD get_security_file( LPCWSTR full_file_name, DWORD access, HAN ...@@ -185,7 +185,7 @@ static inline DWORD get_security_file( LPCWSTR full_file_name, DWORD access, HAN
} }
/* helper function for SE_SERVICE objects in [Get|Set]NamedSecurityInfo */ /* helper function for SE_SERVICE objects in [Get|Set]NamedSecurityInfo */
static inline DWORD get_security_service( LPWSTR full_service_name, DWORD access, HANDLE *service ) static DWORD get_security_service( const WCHAR *full_service_name, DWORD access, HANDLE *service )
{ {
SC_HANDLE manager = OpenSCManagerW( NULL, NULL, access ); SC_HANDLE manager = OpenSCManagerW( NULL, NULL, access );
if (manager) if (manager)
...@@ -199,9 +199,9 @@ static inline DWORD get_security_service( LPWSTR full_service_name, DWORD access ...@@ -199,9 +199,9 @@ static inline DWORD get_security_service( LPWSTR full_service_name, DWORD access
} }
/* helper function for SE_REGISTRY_KEY objects in [Get|Set]NamedSecurityInfo */ /* helper function for SE_REGISTRY_KEY objects in [Get|Set]NamedSecurityInfo */
static inline DWORD get_security_regkey( LPWSTR full_key_name, DWORD access, HANDLE *key ) static DWORD get_security_regkey( const WCHAR *full_key_name, DWORD access, HANDLE *key )
{ {
LPWSTR p = wcschr(full_key_name, '\\'); const WCHAR *p = wcschr(full_key_name, '\\');
int len = p-full_key_name; int len = p-full_key_name;
HKEY hParent; HKEY hParent;
...@@ -2676,7 +2676,7 @@ BOOL WINAPI CreateProcessWithTokenW(HANDLE token, DWORD logon_flags, LPCWSTR app ...@@ -2676,7 +2676,7 @@ BOOL WINAPI CreateProcessWithTokenW(HANDLE token, DWORD logon_flags, LPCWSTR app
/****************************************************************************** /******************************************************************************
* GetNamedSecurityInfoA [ADVAPI32.@] * GetNamedSecurityInfoA [ADVAPI32.@]
*/ */
DWORD WINAPI GetNamedSecurityInfoA(LPSTR pObjectName, DWORD WINAPI GetNamedSecurityInfoA(const char *pObjectName,
SE_OBJECT_TYPE ObjectType, SECURITY_INFORMATION SecurityInfo, SE_OBJECT_TYPE ObjectType, SECURITY_INFORMATION SecurityInfo,
PSID* ppsidOwner, PSID* ppsidGroup, PACL* ppDacl, PACL* ppSacl, PSID* ppsidOwner, PSID* ppsidGroup, PACL* ppDacl, PACL* ppSacl,
PSECURITY_DESCRIPTOR* ppSecurityDescriptor) PSECURITY_DESCRIPTOR* ppSecurityDescriptor)
...@@ -2684,7 +2684,7 @@ DWORD WINAPI GetNamedSecurityInfoA(LPSTR pObjectName, ...@@ -2684,7 +2684,7 @@ DWORD WINAPI GetNamedSecurityInfoA(LPSTR pObjectName,
LPWSTR wstr; LPWSTR wstr;
DWORD r; DWORD r;
TRACE("%s %d %ld %p %p %p %p %p\n", pObjectName, ObjectType, SecurityInfo, TRACE("%s %d %ld %p %p %p %p %p\n", debugstr_a(pObjectName), ObjectType, SecurityInfo,
ppsidOwner, ppsidGroup, ppDacl, ppSacl, ppSecurityDescriptor); ppsidOwner, ppsidGroup, ppDacl, ppSacl, ppSecurityDescriptor);
wstr = strdupAW(pObjectName); wstr = strdupAW(pObjectName);
...@@ -2699,7 +2699,7 @@ DWORD WINAPI GetNamedSecurityInfoA(LPSTR pObjectName, ...@@ -2699,7 +2699,7 @@ DWORD WINAPI GetNamedSecurityInfoA(LPSTR pObjectName,
/****************************************************************************** /******************************************************************************
* GetNamedSecurityInfoW [ADVAPI32.@] * GetNamedSecurityInfoW [ADVAPI32.@]
*/ */
DWORD WINAPI GetNamedSecurityInfoW( LPWSTR name, SE_OBJECT_TYPE type, DWORD WINAPI GetNamedSecurityInfoW( const WCHAR *name, SE_OBJECT_TYPE type,
SECURITY_INFORMATION info, PSID* owner, PSID* group, PACL* dacl, SECURITY_INFORMATION info, PSID* owner, PSID* group, PACL* dacl,
PACL* sacl, PSECURITY_DESCRIPTOR* descriptor ) PACL* sacl, PSECURITY_DESCRIPTOR* descriptor )
{ {
......
...@@ -87,7 +87,7 @@ static BOOL (WINAPI *pConvertSecurityDescriptorToStringSecurityDescriptorA)(PSEC ...@@ -87,7 +87,7 @@ static BOOL (WINAPI *pConvertSecurityDescriptorToStringSecurityDescriptorA)(PSEC
SECURITY_INFORMATION, LPSTR *, PULONG ); SECURITY_INFORMATION, LPSTR *, PULONG );
static BOOL (WINAPI *pSetFileSecurityA)(LPCSTR, SECURITY_INFORMATION, static BOOL (WINAPI *pSetFileSecurityA)(LPCSTR, SECURITY_INFORMATION,
PSECURITY_DESCRIPTOR); PSECURITY_DESCRIPTOR);
static DWORD (WINAPI *pGetNamedSecurityInfoA)(LPSTR, SE_OBJECT_TYPE, SECURITY_INFORMATION, static DWORD (WINAPI *pGetNamedSecurityInfoA)(const char *, SE_OBJECT_TYPE, SECURITY_INFORMATION,
PSID*, PSID*, PACL*, PACL*, PSID*, PSID*, PACL*, PACL*,
PSECURITY_DESCRIPTOR*); PSECURITY_DESCRIPTOR*);
static DWORD (WINAPI *pSetNamedSecurityInfoA)(LPSTR, SE_OBJECT_TYPE, SECURITY_INFORMATION, static DWORD (WINAPI *pSetNamedSecurityInfoA)(LPSTR, SE_OBJECT_TYPE, SECURITY_INFORMATION,
......
...@@ -35,8 +35,8 @@ WINADVAPI DWORD WINAPI GetSecurityInfo( HANDLE, SE_OBJECT_TYPE, SECURITY_INFORM ...@@ -35,8 +35,8 @@ WINADVAPI DWORD WINAPI GetSecurityInfo( HANDLE, SE_OBJECT_TYPE, SECURITY_INFORM
WINADVAPI DWORD WINAPI GetSecurityInfoExA(HANDLE, SE_OBJECT_TYPE, SECURITY_INFORMATION, LPCSTR, LPCSTR, PACTRL_ACCESSA*, PACTRL_AUDITA*, LPSTR*, LPSTR*); WINADVAPI DWORD WINAPI GetSecurityInfoExA(HANDLE, SE_OBJECT_TYPE, SECURITY_INFORMATION, LPCSTR, LPCSTR, PACTRL_ACCESSA*, PACTRL_AUDITA*, LPSTR*, LPSTR*);
WINADVAPI DWORD WINAPI GetSecurityInfoExW(HANDLE, SE_OBJECT_TYPE, SECURITY_INFORMATION, LPCWSTR, LPCWSTR, PACTRL_ACCESSW*, PACTRL_AUDITW*, LPWSTR*, LPWSTR*); WINADVAPI DWORD WINAPI GetSecurityInfoExW(HANDLE, SE_OBJECT_TYPE, SECURITY_INFORMATION, LPCWSTR, LPCWSTR, PACTRL_ACCESSW*, PACTRL_AUDITW*, LPWSTR*, LPWSTR*);
#define GetSecurityInfoEx WINELIB_NAME_AW(GetSecurityInfoEx) #define GetSecurityInfoEx WINELIB_NAME_AW(GetSecurityInfoEx)
WINADVAPI DWORD WINAPI GetNamedSecurityInfoA(LPSTR, SE_OBJECT_TYPE, SECURITY_INFORMATION, PSID*, PSID*, PACL*, PACL*, PSECURITY_DESCRIPTOR*); WINADVAPI DWORD WINAPI GetNamedSecurityInfoA(const char *, SE_OBJECT_TYPE, SECURITY_INFORMATION, PSID*, PSID*, PACL*, PACL*, PSECURITY_DESCRIPTOR*);
WINADVAPI DWORD WINAPI GetNamedSecurityInfoW(LPWSTR, SE_OBJECT_TYPE, SECURITY_INFORMATION, PSID*, PSID*, PACL*, PACL*, PSECURITY_DESCRIPTOR*); WINADVAPI DWORD WINAPI GetNamedSecurityInfoW(const WCHAR *, SE_OBJECT_TYPE, SECURITY_INFORMATION, PSID*, PSID*, PACL*, PACL*, PSECURITY_DESCRIPTOR*);
#define GetNamedSecurityInfo WINELIB_NAME_AW(GetNamedSecurityInfo) #define GetNamedSecurityInfo WINELIB_NAME_AW(GetNamedSecurityInfo)
WINADVAPI DWORD WINAPI SetNamedSecurityInfoA(LPSTR, SE_OBJECT_TYPE, SECURITY_INFORMATION, PSID, PSID, PACL, PACL); WINADVAPI DWORD WINAPI SetNamedSecurityInfoA(LPSTR, SE_OBJECT_TYPE, SECURITY_INFORMATION, PSID, PSID, PACL, PACL);
WINADVAPI DWORD WINAPI SetNamedSecurityInfoW(LPWSTR, SE_OBJECT_TYPE, SECURITY_INFORMATION, PSID, PSID, PACL, PACL); WINADVAPI DWORD WINAPI SetNamedSecurityInfoW(LPWSTR, SE_OBJECT_TYPE, SECURITY_INFORMATION, PSID, PSID, PACL, PACL);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment