https://git.reactos.org/?p=reactos.git;a=commitdiff;h=c98b8dc98ca7ed78a6c1be860d0b73326461620a

commit c98b8dc98ca7ed78a6c1be860d0b73326461620a
Author:     Eric Kohl <eric.k...@reactos.org>
AuthorDate: Tue May 22 14:39:38 2018 +0200
Commit:     Eric Kohl <eric.k...@reactos.org>
CommitDate: Tue May 22 14:39:38 2018 +0200

    [MSGINA] Rename context variable: Domain -> DomainName
---
 dll/win32/msgina/gui.c    | 18 +++++++++---------
 dll/win32/msgina/msgina.c | 14 +++++++-------
 dll/win32/msgina/msgina.h |  2 +-
 3 files changed, 17 insertions(+), 17 deletions(-)

diff --git a/dll/win32/msgina/gui.c b/dll/win32/msgina/gui.c
index 46110df992..c520f07b31 100644
--- a/dll/win32/msgina/gui.c
+++ b/dll/win32/msgina/gui.c
@@ -435,7 +435,7 @@ DoChangePassword(
                        IDS_PASSWORDCHANGED);
 
     if ((wcscmp(UserName, pgContext->UserName) == 0) &&
-        (wcscmp(Domain, pgContext->Domain) == 0) &&
+        (wcscmp(Domain, pgContext->DomainName) == 0) &&
         (wcscmp(OldPassword, pgContext->Password) == 0))
     {
         ZeroMemory(pgContext->Password, sizeof(pgContext->Password));
@@ -472,7 +472,7 @@ ChangePasswordDialogProc(
             SetWindowLongPtrW(hwndDlg, GWLP_USERDATA, (LONG_PTR)pgContext);
 
             SetDlgItemTextW(hwndDlg, IDC_CHANGEPWD_USERNAME, 
pgContext->UserName);
-            SendDlgItemMessageW(hwndDlg, IDC_CHANGEPWD_DOMAIN, CB_ADDSTRING, 
0, (LPARAM)pgContext->Domain);
+            SendDlgItemMessageW(hwndDlg, IDC_CHANGEPWD_DOMAIN, CB_ADDSTRING, 
0, (LPARAM)pgContext->DomainName);
             SendDlgItemMessageW(hwndDlg, IDC_CHANGEPWD_DOMAIN, CB_SETCURSEL, 
0, 0);
             SetFocus(GetDlgItem(hwndDlg, IDC_CHANGEPWD_OLDPWD));
             return TRUE;
@@ -520,7 +520,7 @@ OnInitSecurityDlg(HWND hwnd,
 
     LoadStringW(pgContext->hDllInstance, IDS_LOGONMSG, Buffer1, 
_countof(Buffer1));
 
-    wsprintfW(Buffer2, L"%s\\%s", pgContext->Domain, pgContext->UserName);
+    wsprintfW(Buffer2, L"%s\\%s", pgContext->DomainName, pgContext->UserName);
     wsprintfW(Buffer4, Buffer1, Buffer2);
 
     SetDlgItemTextW(hwnd, IDC_LOGONMSG, Buffer4);
@@ -836,7 +836,7 @@ DoLogon(
 
             Status = DoLoginTasks(pgContext,
                                   pgContext->UserName,
-                                  pgContext->Domain,
+                                  pgContext->DomainName,
                                   pgContext->Password,
                                   &SubStatus);
             if (!NT_SUCCESS(Status))
@@ -910,12 +910,12 @@ SetDomainComboBox(
         lIndex = SendMessageW(hwndDomainComboBox, CB_ADDSTRING, 0, 
(LPARAM)szComputerName);
     }
 
-    if (wcslen(pgContext->Domain) != 0)
+    if (wcslen(pgContext->DomainName) != 0)
     {
-        lFindIndex = SendMessageW(hwndDomainComboBox, CB_FINDSTRINGEXACT, 
(WPARAM)-1, (LPARAM)pgContext->Domain);
+        lFindIndex = SendMessageW(hwndDomainComboBox, CB_FINDSTRINGEXACT, 
(WPARAM)-1, (LPARAM)pgContext->DomainName);
         if (lFindIndex == CB_ERR)
         {
-            lIndex = SendMessageW(hwndDomainComboBox, CB_ADDSTRING, 0, 
(LPARAM)pgContext->Domain);
+            lIndex = SendMessageW(hwndDomainComboBox, CB_ADDSTRING, 0, 
(LPARAM)pgContext->DomainName);
         }
         else
         {
@@ -1125,7 +1125,7 @@ SetLockMessage(HWND hwnd,
 
     LoadStringW(pgContext->hDllInstance, IDS_LOCKMSG, Buffer1, 
_countof(Buffer1));
 
-    wsprintfW(Buffer2, L"%s\\%s", pgContext->Domain, pgContext->UserName);
+    wsprintfW(Buffer2, L"%s\\%s", pgContext->DomainName, pgContext->UserName);
     wsprintfW(Buffer3, Buffer1, Buffer2);
 
     SetDlgItemTextW(hwnd, nDlgItem, Buffer3);
@@ -1179,7 +1179,7 @@ DoUnlock(
             else
             {
                 LoadStringW(pgContext->hDllInstance, IDS_LOCKEDWRONGUSER, 
Buffer1, _countof(Buffer1));
-                wsprintfW(Buffer2, Buffer1, pgContext->Domain, 
pgContext->UserName);
+                wsprintfW(Buffer2, Buffer1, pgContext->DomainName, 
pgContext->UserName);
                 LoadStringW(pgContext->hDllInstance, IDS_COMPUTERLOCKED, 
Buffer1, _countof(Buffer1));
                 MessageBoxW(hwndDlg, Buffer2, Buffer1, MB_OK | MB_ICONERROR);
             }
diff --git a/dll/win32/msgina/msgina.c b/dll/win32/msgina/msgina.c
index 90e59250d2..8f6c3a905a 100644
--- a/dll/win32/msgina/msgina.c
+++ b/dll/win32/msgina/msgina.c
@@ -244,12 +244,12 @@ GetRegistrySettings(PGINA_CONTEXT pgContext)
                           (LPBYTE)&pgContext->UserName,
                           &dwSize);
 
-    dwSize = sizeof(pgContext->Domain);
+    dwSize = sizeof(pgContext->DomainName);
     rc = RegQueryValueExW(hKey,
                           L"DefaultDomainName",
                           NULL,
                           NULL,
-                          (LPBYTE)&pgContext->Domain,
+                          (LPBYTE)&pgContext->DomainName,
                           &dwSize);
 
     dwSize = sizeof(pgContext->Password);
@@ -803,12 +803,12 @@ CreateProfile(
     wcscpy(pgContext->UserName, UserName);
     if (Domain == NULL || wcslen(Domain) == 0)
     {
-        dwLength = _countof(pgContext->Domain);
-        GetComputerNameW(pgContext->Domain, &dwLength);
+        dwLength = _countof(pgContext->DomainName);
+        GetComputerNameW(pgContext->DomainName, &dwLength);
     }
     else
     {
-        wcscpy(pgContext->Domain, Domain);
+        wcscpy(pgContext->DomainName, Domain);
     }
 
     /* Get profile path */
@@ -841,7 +841,7 @@ CreateProfile(
     pProfile->pszProfile = ProfilePath;
 
     cbSize = sizeof(L"LOGONSERVER=\\\\") +
-             wcslen(pgContext->Domain) * sizeof(WCHAR) +
+             wcslen(pgContext->DomainName) * sizeof(WCHAR) +
              sizeof(UNICODE_NULL);
     lpEnvironment = HeapAlloc(GetProcessHeap(), 0, cbSize);
     if (!lpEnvironment)
@@ -850,7 +850,7 @@ CreateProfile(
         goto cleanup;
     }
 
-    StringCbPrintfW(lpEnvironment, cbSize, L"LOGONSERVER=\\\\%ls", 
pgContext->Domain);
+    StringCbPrintfW(lpEnvironment, cbSize, L"LOGONSERVER=\\\\%ls", 
pgContext->DomainName);
     ASSERT(wcslen(lpEnvironment) == cbSize / sizeof(WCHAR) - 2);
     lpEnvironment[cbSize / sizeof(WCHAR) - 1] = UNICODE_NULL;
 
diff --git a/dll/win32/msgina/msgina.h b/dll/win32/msgina/msgina.h
index 2243cb8222..19eabf9eb3 100644
--- a/dll/win32/msgina/msgina.h
+++ b/dll/win32/msgina/msgina.h
@@ -48,7 +48,7 @@ typedef struct
 
     /* Information to be filled during logon */
     WCHAR UserName[256];
-    WCHAR Domain[256];
+    WCHAR DomainName[256];
     WCHAR Password[256];
     SYSTEMTIME LogonTime;
     HANDLE UserToken;

Reply via email to