Skip to content

Commit b781072

Browse files
committed
fixup! win,msi: use localized "Authenticated Users" name
1 parent a107e90 commit b781072

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

tools/msvs/msi/custom_actions.cc

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
#include <msiquery.h>
55
#include <wcautil.h>
66
#include <sddl.h>
7+
#include <Lmcons.h>
78

89
#define GUID_BUFFER_SIZE 39 // {8-4-4-4-12}\0
910

@@ -102,10 +103,10 @@ extern "C" UINT WINAPI BroadcastEnvironmentUpdate(MSIHANDLE hInstall) {
102103
extern "C" UINT WINAPI GetLocalizedUserNames(MSIHANDLE hInstall) {
103104
HRESULT hr = S_OK;
104105
UINT er = ERROR_SUCCESS;
105-
TCHAR userName[MAX_PATH] = {0};
106-
DWORD userNameSize = MAX_PATH;
107-
TCHAR domain[MAX_PATH] = {0};
108-
DWORD domainSize = MAX_PATH;
106+
TCHAR userName[UNLEN + 1] = {0};
107+
DWORD userNameSize = UNLEN + 1;
108+
TCHAR domain[DNLEN + 1] = {0};
109+
DWORD domainSize = DNLEN + 1;
109110
PSID sid;
110111
SID_NAME_USE nameUse;
111112

0 commit comments

Comments
 (0)