mirror of
git://source.winehq.org/git/wine.git
synced 2024-07-21 10:54:10 +00:00
secur32: Print name for EXTENDED_NAME_FORMAT argument.
This commit is contained in:
parent
d5a983ebec
commit
5f1b91e568
|
@ -816,6 +816,33 @@ SECURITY_STATUS WINAPI EnumerateSecurityPackagesA(PULONG pcPackages,
|
|||
return ret;
|
||||
}
|
||||
|
||||
|
||||
static const char *debugstr_NameFormat( EXTENDED_NAME_FORMAT format )
|
||||
{
|
||||
static const char * const names[] =
|
||||
{
|
||||
"NameUnknown",
|
||||
"NameFullyQualifiedDN",
|
||||
"NameSamCompatible",
|
||||
"NameDisplay",
|
||||
NULL,
|
||||
NULL,
|
||||
"NameUniqueId",
|
||||
"NameCanonical",
|
||||
"NameUserPrincipal",
|
||||
"NameCanonicalEx",
|
||||
"NameServicePrincipal",
|
||||
NULL,
|
||||
"NameDnsDomain",
|
||||
"NameGivenName",
|
||||
"NameSurname"
|
||||
};
|
||||
|
||||
if (format < ARRAY_SIZE(names) && names[format]) return names[format];
|
||||
return wine_dbg_sprintf( "%u", format );
|
||||
}
|
||||
|
||||
|
||||
/***********************************************************************
|
||||
* GetComputerObjectNameA (SECUR32.@)
|
||||
*
|
||||
|
@ -847,7 +874,7 @@ BOOLEAN WINAPI GetComputerObjectNameA(
|
|||
LPWSTR bufferW = NULL;
|
||||
ULONG sizeW = *nSize;
|
||||
|
||||
TRACE("(%d %p %p)\n", NameFormat, lpNameBuffer, nSize);
|
||||
TRACE("(%s %p %p)\n", debugstr_NameFormat(NameFormat), lpNameBuffer, nSize);
|
||||
|
||||
if (lpNameBuffer) {
|
||||
if (!(bufferW = malloc(sizeW * sizeof(WCHAR)))) {
|
||||
|
@ -879,7 +906,7 @@ BOOLEAN WINAPI GetComputerObjectNameW(
|
|||
NTSTATUS ntStatus;
|
||||
BOOLEAN status;
|
||||
|
||||
TRACE("(%d %p %p)\n", NameFormat, lpNameBuffer, nSize);
|
||||
TRACE("(%s %p %p)\n", debugstr_NameFormat(NameFormat), lpNameBuffer, nSize);
|
||||
|
||||
if (NameFormat == NameUnknown)
|
||||
{
|
||||
|
@ -1066,7 +1093,7 @@ BOOLEAN WINAPI GetUserNameExA(
|
|||
BOOLEAN rc;
|
||||
LPWSTR bufferW = NULL;
|
||||
ULONG sizeW = *nSize;
|
||||
TRACE("(%d %p %p)\n", NameFormat, lpNameBuffer, nSize);
|
||||
TRACE("(%s %p %p)\n", debugstr_NameFormat(NameFormat), lpNameBuffer, nSize);
|
||||
if (lpNameBuffer) {
|
||||
bufferW = malloc(sizeW * sizeof(WCHAR));
|
||||
if (bufferW == NULL) {
|
||||
|
@ -1098,7 +1125,7 @@ BOOLEAN WINAPI GetUserNameExA(
|
|||
BOOLEAN WINAPI GetUserNameExW(
|
||||
EXTENDED_NAME_FORMAT NameFormat, LPWSTR lpNameBuffer, PULONG nSize)
|
||||
{
|
||||
TRACE("(%d %p %p)\n", NameFormat, lpNameBuffer, nSize);
|
||||
TRACE("(%s %p %p)\n", debugstr_NameFormat(NameFormat), lpNameBuffer, nSize);
|
||||
|
||||
switch (NameFormat)
|
||||
{
|
||||
|
@ -1155,8 +1182,8 @@ BOOLEAN WINAPI TranslateNameA(
|
|||
EXTENDED_NAME_FORMAT DesiredNameFormat, LPSTR lpTranslatedName,
|
||||
PULONG nSize)
|
||||
{
|
||||
FIXME("%p %d %d %p %p\n", lpAccountName, AccountNameFormat,
|
||||
DesiredNameFormat, lpTranslatedName, nSize);
|
||||
FIXME("%p %s %s %p %p\n", lpAccountName, debugstr_NameFormat(AccountNameFormat),
|
||||
debugstr_NameFormat(DesiredNameFormat), lpTranslatedName, nSize);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
|
@ -1165,8 +1192,8 @@ BOOLEAN WINAPI TranslateNameW(
|
|||
EXTENDED_NAME_FORMAT DesiredNameFormat, LPWSTR lpTranslatedName,
|
||||
PULONG nSize)
|
||||
{
|
||||
FIXME("%p %d %d %p %p\n", lpAccountName, AccountNameFormat,
|
||||
DesiredNameFormat, lpTranslatedName, nSize);
|
||||
FIXME("%p %s %s %p %p\n", lpAccountName, debugstr_NameFormat(AccountNameFormat),
|
||||
debugstr_NameFormat(DesiredNameFormat), lpTranslatedName, nSize);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue