diff options
author | Mike Kaganski <mike.kaganski@collabora.com> | 2017-12-06 15:36:19 +0200 |
---|---|---|
committer | Mike Kaganski <mike.kaganski@collabora.com> | 2017-12-06 21:43:32 +0100 |
commit | 5bb95b3d1aef2223fe8c608bf462f22fb7196c6c (patch) | |
tree | bfcd8884ba6e2bb01dd3f515623354fbc99dcb46 /sal | |
parent | fcb23c791e9dbf177e8b603a72198eba0b4dd3b2 (diff) |
Function LookupAccountSidW takes number of characters, not bytes
Change-Id: Ie01feea2c5025f64a7888b85cb5de0c8f6c6f5c2
Reviewed-on: https://gerrit.libreoffice.org/45955
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Diffstat (limited to 'sal')
-rw-r--r-- | sal/osl/w32/security.cxx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sal/osl/w32/security.cxx b/sal/osl/w32/security.cxx index 120b5c98258d..77bce5d9bbbc 100644 --- a/sal/osl/w32/security.cxx +++ b/sal/osl/w32/security.cxx @@ -786,8 +786,8 @@ static bool SAL_CALL getUserNameImpl(oslSecurity Security, rtl_uString **strName sal_Unicode UserName[128]; sal_Unicode DomainName[128]; sal_Unicode Name[257]; - DWORD nUserName = sizeof(UserName); - DWORD nDomainName = sizeof(DomainName); + DWORD nUserName = SAL_N_ELEMENTS(UserName); + DWORD nDomainName = SAL_N_ELEMENTS(DomainName); SID_NAME_USE sUse; if (LookupAccountSidW(nullptr, reinterpret_cast<PTOKEN_USER>(pInfoBuffer)->User.Sid, |