version 1.58, 2005/11/01 23:24:49
|
version 1.59, 2005/11/02 20:16:41
|
|
|
| |
//Bug 3076 fix | //Bug 3076 fix |
wchar_t fullUserName[UNLEN+1]; | wchar_t fullUserName[UNLEN+1]; |
DWORD userNameSize = sizeof(fullUserName); |
DWORD userNameSize = sizeof(fullUserName)/sizeof(fullUserName[0]); |
wchar_t computerName[MAX_COMPUTERNAME_LENGTH+1]; | wchar_t computerName[MAX_COMPUTERNAME_LENGTH+1]; |
DWORD computerNameSize = sizeof(computerName); |
DWORD computerNameSize = sizeof(computerName)/sizeof(computerName[0]); |
wchar_t userName[UNLEN+1]; | wchar_t userName[UNLEN+1]; |
wchar_t userDomain[UNLEN+1]; | wchar_t userDomain[UNLEN+1]; |
String userId; | String userId; |
|
|
| |
// UNLEN (256) is the limit, not including null | // UNLEN (256) is the limit, not including null |
wchar_t pUserName[256+1] = {0}; | wchar_t pUserName[256+1] = {0}; |
DWORD nSize = sizeof(pUserName); |
DWORD nSize = sizeof(pUserName)/sizeof(pUserName[0]); |
| |
retcode = GetUserNameW(pUserName, &nSize); | retcode = GetUserNameW(pUserName, &nSize); |
if (retcode == 0) | if (retcode == 0) |