ReactOS.org
Sign In
Sign Up
Sign In
Sign Up
Manage this list
×
Keyboard Shortcuts
Thread View
j
: Next unread message
k
: Previous unread message
j a
: Jump to all threads
j l
: Jump to MailingList overview
2024
December
November
October
September
August
July
June
May
April
March
February
January
2023
December
November
October
September
August
July
June
May
April
March
February
January
2022
December
November
October
September
August
July
June
May
April
March
February
January
2021
December
November
October
September
August
July
June
May
April
March
February
January
2020
December
November
October
September
August
July
June
May
April
March
February
January
2019
December
November
October
September
August
July
June
May
April
March
February
January
2018
December
November
October
September
August
July
June
May
April
March
February
January
2017
December
November
October
September
August
July
June
May
April
March
February
January
2016
December
November
October
September
August
July
June
May
April
March
February
January
2015
December
November
October
September
August
July
June
May
April
March
February
January
2014
December
November
October
September
August
July
June
May
April
March
February
January
2013
December
November
October
September
August
July
June
May
April
March
February
January
2012
December
November
October
September
August
July
June
May
April
March
February
January
2011
December
November
October
September
August
July
June
May
April
March
February
January
2010
December
November
October
September
August
July
June
May
April
March
February
January
2009
December
November
October
September
August
July
June
May
April
March
February
January
2008
December
November
October
September
August
July
June
May
April
March
February
January
2007
December
November
October
September
August
July
June
May
April
March
February
January
2006
December
November
October
September
August
July
June
May
April
March
February
January
2005
December
November
October
September
August
July
June
May
April
March
February
January
2004
December
November
October
September
August
July
June
May
April
March
February
List overview
Download
Ros-diffs
February 2013
----- 2024 -----
December 2024
November 2024
October 2024
September 2024
August 2024
July 2024
June 2024
May 2024
April 2024
March 2024
February 2024
January 2024
----- 2023 -----
December 2023
November 2023
October 2023
September 2023
August 2023
July 2023
June 2023
May 2023
April 2023
March 2023
February 2023
January 2023
----- 2022 -----
December 2022
November 2022
October 2022
September 2022
August 2022
July 2022
June 2022
May 2022
April 2022
March 2022
February 2022
January 2022
----- 2021 -----
December 2021
November 2021
October 2021
September 2021
August 2021
July 2021
June 2021
May 2021
April 2021
March 2021
February 2021
January 2021
----- 2020 -----
December 2020
November 2020
October 2020
September 2020
August 2020
July 2020
June 2020
May 2020
April 2020
March 2020
February 2020
January 2020
----- 2019 -----
December 2019
November 2019
October 2019
September 2019
August 2019
July 2019
June 2019
May 2019
April 2019
March 2019
February 2019
January 2019
----- 2018 -----
December 2018
November 2018
October 2018
September 2018
August 2018
July 2018
June 2018
May 2018
April 2018
March 2018
February 2018
January 2018
----- 2017 -----
December 2017
November 2017
October 2017
September 2017
August 2017
July 2017
June 2017
May 2017
April 2017
March 2017
February 2017
January 2017
----- 2016 -----
December 2016
November 2016
October 2016
September 2016
August 2016
July 2016
June 2016
May 2016
April 2016
March 2016
February 2016
January 2016
----- 2015 -----
December 2015
November 2015
October 2015
September 2015
August 2015
July 2015
June 2015
May 2015
April 2015
March 2015
February 2015
January 2015
----- 2014 -----
December 2014
November 2014
October 2014
September 2014
August 2014
July 2014
June 2014
May 2014
April 2014
March 2014
February 2014
January 2014
----- 2013 -----
December 2013
November 2013
October 2013
September 2013
August 2013
July 2013
June 2013
May 2013
April 2013
March 2013
February 2013
January 2013
----- 2012 -----
December 2012
November 2012
October 2012
September 2012
August 2012
July 2012
June 2012
May 2012
April 2012
March 2012
February 2012
January 2012
----- 2011 -----
December 2011
November 2011
October 2011
September 2011
August 2011
July 2011
June 2011
May 2011
April 2011
March 2011
February 2011
January 2011
----- 2010 -----
December 2010
November 2010
October 2010
September 2010
August 2010
July 2010
June 2010
May 2010
April 2010
March 2010
February 2010
January 2010
----- 2009 -----
December 2009
November 2009
October 2009
September 2009
August 2009
July 2009
June 2009
May 2009
April 2009
March 2009
February 2009
January 2009
----- 2008 -----
December 2008
November 2008
October 2008
September 2008
August 2008
July 2008
June 2008
May 2008
April 2008
March 2008
February 2008
January 2008
----- 2007 -----
December 2007
November 2007
October 2007
September 2007
August 2007
July 2007
June 2007
May 2007
April 2007
March 2007
February 2007
January 2007
----- 2006 -----
December 2006
November 2006
October 2006
September 2006
August 2006
July 2006
June 2006
May 2006
April 2006
March 2006
February 2006
January 2006
----- 2005 -----
December 2005
November 2005
October 2005
September 2005
August 2005
July 2005
June 2005
May 2005
April 2005
March 2005
February 2005
January 2005
----- 2004 -----
December 2004
November 2004
October 2004
September 2004
August 2004
July 2004
June 2004
May 2004
April 2004
March 2004
February 2004
ros-diffs@reactos.org
11 participants
125 discussions
Start a n
N
ew thread
[tfaber] 58262: [EXPLORER_NEW] - Process startup items before creating the desktop. Fix some comments, add TODOs. Based on patch by Edijs Kolesnikovičs. CORE-6896 #resolve
by tfaber@svn.reactos.org
Author: tfaber Date: Sat Feb 2 10:49:58 2013 New Revision: 58262 URL:
http://svn.reactos.org/svn/reactos?rev=58262&view=rev
Log: [EXPLORER_NEW] - Process startup items before creating the desktop. Fix some comments, add TODOs. Based on patch by Edijs Kolesnikovičs. CORE-6896 #resolve Modified: trunk/reactos/base/shell/explorer-new/explorer.c trunk/reactos/base/shell/explorer-new/startup.c Modified: trunk/reactos/base/shell/explorer-new/explorer.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/shell/explorer-new/ex…
============================================================================== --- trunk/reactos/base/shell/explorer-new/explorer.c [iso-8859-1] (original) +++ trunk/reactos/base/shell/explorer-new/explorer.c [iso-8859-1] Sat Feb 2 10:49:58 2013 @@ -401,6 +401,8 @@ InitCommonControls(); OleInitialize(NULL); + ProcessStartupItems(); + if (GetShellWindow() == NULL) CreateShellDesktop = TRUE; @@ -424,8 +426,6 @@ /* WinXP: Notify msgina to hide the welcome screen */ if (!SetShellReadyEvent(TEXT("msgina: ShellReadyEvent"))) SetShellReadyEvent(TEXT("Global\\msgina: ShellReadyEvent")); - - ProcessStartupItems(); } else { Modified: trunk/reactos/base/shell/explorer-new/startup.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/shell/explorer-new/st…
============================================================================== --- trunk/reactos/base/shell/explorer-new/startup.c [iso-8859-1] (original) +++ trunk/reactos/base/shell/explorer-new/startup.c [iso-8859-1] Sat Feb 2 10:49:58 2013 @@ -26,19 +26,16 @@ * Also, 119941 has some info on grpconv.exe * The operations performed are (by order of execution): * - * Startup (before the user logs in) - * - Services (NT, ?semi-synchronous?, not implemented yet) - * - HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\RunServicesOnce (9x, asynch) - * - HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\RunServices (9x, asynch) - * * After log in - * - HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\RunOnce (all, synch) - * - HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Run (all, asynch) - * - HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Run (all, asynch) - * - Startup folders (all, ?asynch?, no imp) - * - HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\RunOnce (all, asynch) - * - * Somewhere in there is processing the RunOnceEx entries (also no imp) + * - HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\RunOnceEx (synch, no imp) + * - HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\RunOnce (synch) + * - HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Run (asynch) + * - HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Run (asynch) + * - All users Startup folder "%ALLUSERSPROFILE%\Start Menu\Programs\Startup" (asynch, no imp) + * - Current user Startup folder "%USERPROFILE%\Start Menu\Programs\Startup" (asynch, no imp) + * - HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\RunOnce (asynch) + * + * None is processed in Safe Mode // FIXME: Check RunOnceEx in Safe Mode */ #include "precomp.h" @@ -110,9 +107,6 @@ static BOOL ProcessRunKeys(HKEY hkRoot, LPCWSTR szKeyName, BOOL bDelete, BOOL bSynchronous) { - static const WCHAR WINKEY_NAME[]={'S','o','f','t','w','a','r','e','\\', - 'M','i','c','r','o','s','o','f','t','\\','W','i','n','d','o','w','s','\\', - 'C','u','r','r','e','n','t','V','e','r','s','i','o','n',0}; HKEY hkWin = NULL, hkRun=NULL; LONG res = ERROR_SUCCESS; DWORD i, nMaxCmdLine = 0, nMaxValue = 0; @@ -124,7 +118,7 @@ else wprintf(L"processing %s entries under HKCU\n", szKeyName); - if ((res = RegOpenKeyExW(hkRoot, WINKEY_NAME, 0, KEY_READ, &hkWin)) != ERROR_SUCCESS) + if ((res = RegOpenKeyExW(hkRoot, L"Software\\Microsoft\\Windows\\CurrentVersion", 0, KEY_READ, &hkWin)) != ERROR_SUCCESS) { printf("RegOpenKey failed on Software\\Microsoft\\Windows\\CurrentVersion (%ld)\n", res); @@ -180,9 +174,9 @@ goto end; } - while(i > 0) - { - DWORD nValLength=nMaxValue, nDataLength=nMaxCmdLine; + while (i > 0) + { + DWORD nValLength = nMaxValue, nDataLength = nMaxCmdLine; DWORD type; --i; @@ -237,6 +231,7 @@ int ProcessStartupItems(VOID) { + /* TODO: ProcessRunKeys already checks SM_CLEANBOOT -- items prefixed with * should probably run even in safe mode */ BOOL bNormalBoot = GetSystemMetrics(SM_CLEANBOOT) == 0; /* Perform the operations that are performed every boot */ /* First, set the current directory to SystemRoot */ TCHAR gen_path[MAX_PATH]; @@ -284,6 +279,8 @@ * stopping if one fails, skipping if necessary. */ res = TRUE; + /* TODO: RunOnceEx */ + if (res && (SHRestricted(REST_NOLOCALMACHINERUNONCE) == 0)) res = ProcessRunKeys(HKEY_LOCAL_MACHINE, L"RunOnce", TRUE, TRUE); @@ -293,6 +290,11 @@ if (res && bNormalBoot && (SHRestricted(REST_NOCURRENTUSERRUNONCE) == 0)) res = ProcessRunKeys(HKEY_CURRENT_USER, L"Run", FALSE, FALSE); + /* TODO: All users Startup folder */ + + /* TODO: Current user Startup folder */ + + /* TODO: HKCU\RunOnce runs even if StartupHasBeenRun exists */ if (res && bNormalBoot && (SHRestricted(REST_NOCURRENTUSERRUNONCE) == 0)) res = ProcessRunKeys(HKEY_CURRENT_USER, L"RunOnce", TRUE, FALSE);
11 years, 10 months
1
0
0
0
[tfaber] 58261: [EXPLORER_NEW] - Handle tray window notification to open start menu. By Edijs Kolesnikovičs & Grégori Macário Harbs. CORE-6874 #resolve
by tfaber@svn.reactos.org
Author: tfaber Date: Sat Feb 2 10:33:08 2013 New Revision: 58261 URL:
http://svn.reactos.org/svn/reactos?rev=58261&view=rev
Log: [EXPLORER_NEW] - Handle tray window notification to open start menu. By Edijs Kolesnikovičs & Grégori Macário Harbs. CORE-6874 #resolve Modified: trunk/reactos/base/shell/explorer-new/precomp.h trunk/reactos/base/shell/explorer-new/traywnd.c Modified: trunk/reactos/base/shell/explorer-new/precomp.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/shell/explorer-new/pr…
============================================================================== --- trunk/reactos/base/shell/explorer-new/precomp.h [iso-8859-1] (original) +++ trunk/reactos/base/shell/explorer-new/precomp.h [iso-8859-1] Sat Feb 2 10:33:08 2013 @@ -170,6 +170,8 @@ * traywnd.c */ +#define TWM_OPENSTARTMENU (WM_USER + 260) + typedef HMENU (*PCREATECTXMENU)(IN HWND hWndOwner, IN PVOID *ppcmContext, IN PVOID Context OPTIONAL); @@ -426,7 +428,7 @@ * taskswnd.c */ -#define TSWM_ENABLEGROUPING (WM_USER + 1) +#define TSWM_ENABLEGROUPING (WM_USER + 1) #define TSWM_UPDATETASKBARPOS (WM_USER + 2) BOOL Modified: trunk/reactos/base/shell/explorer-new/traywnd.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/shell/explorer-new/tr…
============================================================================== --- trunk/reactos/base/shell/explorer-new/traywnd.c [iso-8859-1] (original) +++ trunk/reactos/base/shell/explorer-new/traywnd.c [iso-8859-1] Sat Feb 2 10:33:08 2013 @@ -2532,6 +2532,10 @@ DestroyWindow(hwnd); break; + case TWM_OPENSTARTMENU: + SendMessage(This->hWnd, WM_COMMAND, MAKEWPARAM(BN_CLICKED, IDC_STARTBTN), (LPARAM)This->hwndStart); + break; + case WM_COMMAND: if ((HWND)lParam == This->hwndStart) {
11 years, 10 months
1
0
0
0
[hbelusca] 58260: [CONSRV] - Further compactify console allocation / attach code by putting common code into helper functions. - Now, the default title of a console window is... "ReactOS Console" (...
by hbelusca@svn.reactos.org
Author: hbelusca Date: Fri Feb 1 23:36:23 2013 New Revision: 58260 URL:
http://svn.reactos.org/svn/reactos?rev=58260&view=rev
Log: [CONSRV] - Further compactify console allocation / attach code by putting common code into helper functions. - Now, the default title of a console window is... "ReactOS Console" (and not command prompt since a console window isn't only reserved to command prompts). Modified: branches/ros-csrss/win32ss/user/consrv/console.c branches/ros-csrss/win32ss/user/consrv/consrv.h branches/ros-csrss/win32ss/user/consrv/handle.c branches/ros-csrss/win32ss/user/consrv/lang/bg-BG.rc branches/ros-csrss/win32ss/user/consrv/lang/cs-CZ.rc branches/ros-csrss/win32ss/user/consrv/lang/de-DE.rc branches/ros-csrss/win32ss/user/consrv/lang/el-GR.rc branches/ros-csrss/win32ss/user/consrv/lang/en-US.rc branches/ros-csrss/win32ss/user/consrv/lang/es-ES.rc branches/ros-csrss/win32ss/user/consrv/lang/fr-FR.rc branches/ros-csrss/win32ss/user/consrv/lang/id-ID.rc branches/ros-csrss/win32ss/user/consrv/lang/it-IT.rc branches/ros-csrss/win32ss/user/consrv/lang/ja-JP.rc branches/ros-csrss/win32ss/user/consrv/lang/no-NO.rc branches/ros-csrss/win32ss/user/consrv/lang/pl-PL.rc branches/ros-csrss/win32ss/user/consrv/lang/pt-BR.rc branches/ros-csrss/win32ss/user/consrv/lang/ro-RO.rc branches/ros-csrss/win32ss/user/consrv/lang/ru-RU.rc branches/ros-csrss/win32ss/user/consrv/lang/sk-SK.rc branches/ros-csrss/win32ss/user/consrv/lang/sv-SE.rc branches/ros-csrss/win32ss/user/consrv/lang/tr-TR.rc branches/ros-csrss/win32ss/user/consrv/lang/uk-UA.rc branches/ros-csrss/win32ss/user/consrv/lang/zh-CN.rc branches/ros-csrss/win32ss/user/consrv/lang/zh-TW.rc branches/ros-csrss/win32ss/user/consrv/resource.h Modified: branches/ros-csrss/win32ss/user/consrv/console.c URL:
http://svn.reactos.org/svn/reactos/branches/ros-csrss/win32ss/user/consrv/c…
============================================================================== --- branches/ros-csrss/win32ss/user/consrv/console.c [iso-8859-1] (original) +++ branches/ros-csrss/win32ss/user/consrv/console.c [iso-8859-1] Fri Feb 1 23:36:23 2013 @@ -121,13 +121,13 @@ Console->Title.MaximumLength = Console->Title.Length = 0; Console->Title.Buffer = NULL; - if (LoadStringW(ConSrvDllInstance, IDS_COMMAND_PROMPT, Title, sizeof(Title) / sizeof(Title[0]))) + if (LoadStringW(ConSrvDllInstance, IDS_CONSOLE_TITLE, Title, sizeof(Title) / sizeof(Title[0]))) { RtlCreateUnicodeString(&Console->Title, Title); } else { - RtlCreateUnicodeString(&Console->Title, L"Command Prompt"); + RtlCreateUnicodeString(&Console->Title, L"ReactOS Console"); } InitializeCriticalSection(&Console->Lock); @@ -363,10 +363,6 @@ DPRINT1("Process already has a console\n"); return STATUS_ACCESS_DENIED; } - -/******************************************************************************/ -/** This comes from ConSrvConnect!! **/ - DPRINT1("SrvAllocConsole - Checkpoint 1\n"); /* * We are about to create a new console. However when ConSrvNewProcess @@ -383,33 +379,14 @@ /* Initialize a new Console owned by the Console Leader Process */ Status = ConSrvAllocateConsole(ProcessData, - &AllocConsoleRequest->InputHandle, - &AllocConsoleRequest->OutputHandle, - &AllocConsoleRequest->ErrorHandle, - AllocConsoleRequest->ShowCmd, - ConsoleLeader); + &AllocConsoleRequest->InputHandle, + &AllocConsoleRequest->OutputHandle, + &AllocConsoleRequest->ErrorHandle, + AllocConsoleRequest->ShowCmd, + ConsoleLeader); if (!NT_SUCCESS(Status)) { DPRINT1("Console allocation failed\n"); - return Status; - } - - /* Add a reference count because the process is tied to the console */ - _InterlockedIncrement(&ProcessData->Console->ReferenceCount); - - /* Insert the process into the processes list of the console */ - InsertHeadList(&ProcessData->Console->ProcessList, &ProcessData->ConsoleLink); - - /* Duplicate the Event */ - Status = NtDuplicateObject(NtCurrentProcess(), - ProcessData->Console->InputBuffer.ActiveEvent, - ProcessData->Process->ProcessHandle, - &ProcessData->ConsoleEvent, - EVENT_ALL_ACCESS, 0, 0); - if (!NT_SUCCESS(Status)) - { - DPRINT1("NtDuplicateObject() failed: %lu\n", Status); - ConSrvRemoveConsole(ProcessData); return Status; } @@ -422,7 +399,6 @@ /* Set the Ctrl Dispatcher */ ProcessData->CtrlDispatcher = AllocConsoleRequest->CtrlDispatcher; DPRINT("CONSRV: CtrlDispatcher address: %x\n", ProcessData->CtrlDispatcher); -/******************************************************************************/ return STATUS_SUCCESS; } @@ -446,6 +422,7 @@ return STATUS_ACCESS_DENIED; } + /* Check whether we try to attach to the parent's console */ if (ProcessId == ULongToHandle(ATTACH_PARENT_PROCESS)) { PROCESS_BASIC_INFORMATION ProcessInfo; @@ -468,16 +445,19 @@ DPRINT("Parent process ID = %lu\n", ProcessId); } - /* Lock the target process via its PID */ - DPRINT1("Lock process Id %lu\n", ProcessId); + /* Lock the source process via its PID */ Status = CsrLockProcessByClientId(ProcessId, &SourceProcess); - DPRINT1("Lock process Status %lu\n", Status); + DPRINT1("Lock process Id %lu - Status %lu\n", ProcessId, Status); if (!NT_SUCCESS(Status)) return Status; - DPRINT1("AttachConsole OK\n"); - -/******************************************************************************/ -/** This comes from ConSrvNewProcess!! **/ + SourceProcessData = ConsoleGetPerProcessData(SourceProcess); + + DPRINT1("SourceProcessData->Console = 0x%p\n", SourceProcessData->Console); + if (SourceProcessData->Console == NULL) + { + Status = STATUS_INVALID_HANDLE; + goto Quit; + } /* * We are about to create a new console. However when ConSrvNewProcess @@ -496,54 +476,15 @@ * Inherit the console from the parent, * if any, otherwise return an error. */ - DPRINT1("SourceProcessData->Console = 0x%p\n", SourceProcessData->Console); - if (SourceProcessData->Console == NULL) - { - Status = STATUS_INVALID_HANDLE; - goto Quit; - } - TargetProcessData->Console = SourceProcessData->Console; - - /// REMARK: This code comes from ConSrvAllocateConsole. - /* Initialize the handles table */ - Status = ConSrvInitHandlesTable(TargetProcessData, - &AttachConsoleRequest->InputHandle, - &AttachConsoleRequest->OutputHandle, - &AttachConsoleRequest->ErrorHandle); + Status = ConSrvInheritConsole(TargetProcessData, + SourceProcessData->Console, + TRUE, + &AttachConsoleRequest->InputHandle, + &AttachConsoleRequest->OutputHandle, + &AttachConsoleRequest->ErrorHandle); if (!NT_SUCCESS(Status)) { - DPRINT1("Failed to initialize the handles table\n"); - - // ConSrvRemoveConsole(TargetProcessData); - TargetProcessData->Console = NULL; - goto Quit; - } - -/******************************************************************************/ - -/******************************************************************************/ -/** This comes from ConSrvConnect / SrvAllocConsole!! **/ - /* Add a reference count because the process is tied to the console */ - _InterlockedIncrement(&TargetProcessData->Console->ReferenceCount); - - /* Insert the process into the processes list of the console */ - InsertHeadList(&TargetProcessData->Console->ProcessList, &TargetProcessData->ConsoleLink); - - /** Here, we inherited the console handles from the "source" process, - ** so no need to reinitialize the handles table. **/ - - DPRINT1("SrvAttachConsole - Checkpoint\n"); - - /* Duplicate the Event */ - Status = NtDuplicateObject(NtCurrentProcess(), - TargetProcessData->Console->InputBuffer.ActiveEvent, - TargetProcessData->Process->ProcessHandle, - &TargetProcessData->ConsoleEvent, - EVENT_ALL_ACCESS, 0, 0); - if (!NT_SUCCESS(Status)) - { - DPRINT1("NtDuplicateObject() failed: %lu\n", Status); - ConSrvRemoveConsole(TargetProcessData); + DPRINT1("Console inheritance failed\n"); goto Quit; } @@ -558,14 +499,10 @@ DPRINT("CONSRV: CtrlDispatcher address: %x\n", TargetProcessData->CtrlDispatcher); Status = STATUS_SUCCESS; -/******************************************************************************/ Quit: - DPRINT1("SrvAttachConsole - exiting 1\n"); - /* Unlock the "source" process */ + /* Unlock the "source" process and exit */ CsrUnlockProcess(SourceProcess); - DPRINT1("SrvAttachConsole - exiting 2\n"); - return Status; } Modified: branches/ros-csrss/win32ss/user/consrv/consrv.h URL:
http://svn.reactos.org/svn/reactos/branches/ros-csrss/win32ss/user/consrv/c…
============================================================================== --- branches/ros-csrss/win32ss/user/consrv/consrv.h [iso-8859-1] (original) +++ branches/ros-csrss/win32ss/user/consrv/consrv.h [iso-8859-1] Fri Feb 1 23:36:23 2013 @@ -183,6 +183,12 @@ PHANDLE pErrorHandle, int ShowCmd, PCSR_PROCESS CsrProcess); +NTSTATUS FASTCALL ConSrvInheritConsole(PCONSOLE_PROCESS_DATA ProcessData, + struct _CONSOLE* Console, + BOOL CreateNewHandlesTable, + PHANDLE pInputHandle, + PHANDLE pOutputHandle, + PHANDLE pErrorHandle); VOID FASTCALL ConSrvRemoveConsole(PCONSOLE_PROCESS_DATA ProcessData); NTSTATUS FASTCALL ConSrvGetConsole(PCONSOLE_PROCESS_DATA ProcessData, struct _CONSOLE** Console, Modified: branches/ros-csrss/win32ss/user/consrv/handle.c URL:
http://svn.reactos.org/svn/reactos/branches/ros-csrss/win32ss/user/consrv/h…
============================================================================== --- branches/ros-csrss/win32ss/user/consrv/handle.c [iso-8859-1] (original) +++ branches/ros-csrss/win32ss/user/consrv/handle.c [iso-8859-1] Fri Feb 1 23:36:23 2013 @@ -420,21 +420,91 @@ /* Initialize the handles table */ Status = ConSrvInitHandlesTable(ProcessData, - pInputHandle, - pOutputHandle, - pErrorHandle); + pInputHandle, + pOutputHandle, + pErrorHandle); if (!NT_SUCCESS(Status)) { DPRINT1("Failed to initialize the handles table\n"); - - // ConSrvRemoveConsole(ProcessData); ConSrvDeleteConsole(ProcessData->Console); ProcessData->Console = NULL; - return Status; } - return Status; + /* Duplicate the Input Event */ + Status = NtDuplicateObject(NtCurrentProcess(), + ProcessData->Console->InputBuffer.ActiveEvent, + ProcessData->Process->ProcessHandle, + &ProcessData->ConsoleEvent, + EVENT_ALL_ACCESS, 0, 0); + if (!NT_SUCCESS(Status)) + { + DPRINT1("NtDuplicateObject() failed: %lu\n", Status); + ConSrvFreeHandlesTable(ProcessData); + ConSrvDeleteConsole(ProcessData->Console); + ProcessData->Console = NULL; + return Status; + } + + /* Insert the process into the processes list of the console */ + InsertHeadList(&ProcessData->Console->ProcessList, &ProcessData->ConsoleLink); + + /* Add a reference count because the process is tied to the console */ + _InterlockedIncrement(&ProcessData->Console->ReferenceCount); + + return STATUS_SUCCESS; +} + +NTSTATUS +FASTCALL +ConSrvInheritConsole(PCONSOLE_PROCESS_DATA ProcessData, + PCONSOLE Console, + BOOL CreateNewHandlesTable, + PHANDLE pInputHandle, + PHANDLE pOutputHandle, + PHANDLE pErrorHandle) +{ + NTSTATUS Status = STATUS_SUCCESS; + + /* Inherit the console */ + ProcessData->Console = Console; + + if (CreateNewHandlesTable) + { + /* Initialize the handles table */ + Status = ConSrvInitHandlesTable(ProcessData, + pInputHandle, + pOutputHandle, + pErrorHandle); + if (!NT_SUCCESS(Status)) + { + DPRINT1("Failed to initialize the handles table\n"); + ProcessData->Console = NULL; + return Status; + } + } + + /* Duplicate the Input Event */ + Status = NtDuplicateObject(NtCurrentProcess(), + ProcessData->Console->InputBuffer.ActiveEvent, + ProcessData->Process->ProcessHandle, + &ProcessData->ConsoleEvent, + EVENT_ALL_ACCESS, 0, 0); + if (!NT_SUCCESS(Status)) + { + DPRINT1("NtDuplicateObject() failed: %lu\n", Status); + ConSrvFreeHandlesTable(ProcessData); // NOTE: Always free the handles table. + ProcessData->Console = NULL; + return Status; + } + + /* Insert the process into the processes list of the console */ + InsertHeadList(&ProcessData->Console->ProcessList, &ProcessData->ConsoleLink); + + /* Add a reference count because the process is tied to the console */ + _InterlockedIncrement(&ProcessData->Console->ReferenceCount); + + return STATUS_SUCCESS; } VOID @@ -521,7 +591,7 @@ PCONSOLE_PROCESS_DATA SourceProcessData, TargetProcessData; - DPRINT1("ConSrvNewProcess inside\n"); + DPRINT1("ConSrvNewProcess\n"); DPRINT1("SourceProcess = 0x%p ; TargetProcess = 0x%p\n", SourceProcess, TargetProcess); /* An empty target process is invalid */ @@ -565,17 +635,14 @@ NTSTATUS Status; Status = ConSrvInheritHandlesTable(SourceProcessData, TargetProcessData); - if (!NT_SUCCESS(Status)) - { - return Status; - } - - /* Temporary "inherit" the console from the parent */ + if (!NT_SUCCESS(Status)) return Status; + + /* Temporary save the parent's console */ TargetProcessData->ParentConsole = SourceProcessData->Console; } else { - DPRINT1("ConSrvNewProcess - We don't launch a Console process : SourceProcessData->Console = 0x%p ; TargetProcess->Flags = %lu\n", SourceProcessData->Console, TargetProcess->Flags); + DPRINT1("ConSrvNewProcess - We don't inherit a handle table : SourceProcessData->Console = 0x%p ; TargetProcess->Flags = %lu\n", SourceProcessData->Console, TargetProcess->Flags); } return STATUS_SUCCESS; @@ -632,11 +699,11 @@ /* Initialize a new Console owned by the Console Leader Process */ Status = ConSrvAllocateConsole(ProcessData, - &ConnectInfo->InputHandle, - &ConnectInfo->OutputHandle, - &ConnectInfo->ErrorHandle, - ConnectInfo->ShowCmd, - CsrProcess); + &ConnectInfo->InputHandle, + &ConnectInfo->OutputHandle, + &ConnectInfo->ErrorHandle, + ConnectInfo->ShowCmd, + CsrProcess); if (!NT_SUCCESS(Status)) { DPRINT1("Console allocation failed\n"); @@ -648,27 +715,17 @@ DPRINT1("ConSrvConnect - Reuse current (parent's) console\n"); /* Reuse our current console */ - ProcessData->Console = ConnectInfo->Console; - } - - /* Add a reference count because the process is tied to the console */ - _InterlockedIncrement(&ProcessData->Console->ReferenceCount); - - /* Insert the process into the processes list of the console */ - InsertHeadList(&ProcessData->Console->ProcessList, &ProcessData->ConsoleLink); - - /// TODO: Move this up ? - /* Duplicate the Event */ - Status = NtDuplicateObject(NtCurrentProcess(), - ProcessData->Console->InputBuffer.ActiveEvent, - ProcessData->Process->ProcessHandle, - &ProcessData->ConsoleEvent, - EVENT_ALL_ACCESS, 0, 0); - if (!NT_SUCCESS(Status)) - { - DPRINT1("NtDuplicateObject() failed: %lu\n", Status); - ConSrvRemoveConsole(ProcessData); - return Status; + Status = ConSrvInheritConsole(ProcessData, + ConnectInfo->Console, + FALSE, + NULL, // &ConnectInfo->InputHandle, + NULL, // &ConnectInfo->OutputHandle, + NULL); // &ConnectInfo->ErrorHandle); + if (!NT_SUCCESS(Status)) + { + DPRINT1("Console inheritance failed\n"); + return Status; + } } /* Return it to the caller */ @@ -694,7 +751,8 @@ * This function is called whenever a new process (GUI or CUI) is destroyed. **************************************************************************/ - DPRINT1("ConSrvDisconnect called\n"); + DPRINT1("ConSrvDisconnect\n"); + if ( ProcessData->Console != NULL || ProcessData->HandleTable != NULL ) { Modified: branches/ros-csrss/win32ss/user/consrv/lang/bg-BG.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-csrss/win32ss/user/consrv/l…
============================================================================== --- branches/ros-csrss/win32ss/user/consrv/lang/bg-BG.rc [iso-8859-1] (original) +++ branches/ros-csrss/win32ss/user/consrv/lang/bg-BG.rc [iso-8859-1] Fri Feb 1 23:36:23 2013 @@ -25,5 +25,5 @@ IDS_SCROLLUP "Ïðåëèñòâàíå íàãîðå" IDS_SCROLLDOWN "Ïðåëèñòâàíå íàäîëó" - IDS_COMMAND_PROMPT "Command Prompt" + IDS_CONSOLE_TITLE "ReactOS Console" END Modified: branches/ros-csrss/win32ss/user/consrv/lang/cs-CZ.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-csrss/win32ss/user/consrv/l…
============================================================================== --- branches/ros-csrss/win32ss/user/consrv/lang/cs-CZ.rc [iso-8859-1] (original) +++ branches/ros-csrss/win32ss/user/consrv/lang/cs-CZ.rc [iso-8859-1] Fri Feb 1 23:36:23 2013 @@ -24,5 +24,5 @@ IDS_SCROLLUP "Posunout nahoru" IDS_SCROLLDOWN "Posunout dolù" - IDS_COMMAND_PROMPT "Pøíkazový øádek" + IDS_CONSOLE_TITLE "ReactOS Console" END Modified: branches/ros-csrss/win32ss/user/consrv/lang/de-DE.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-csrss/win32ss/user/consrv/l…
============================================================================== --- branches/ros-csrss/win32ss/user/consrv/lang/de-DE.rc [iso-8859-1] (original) +++ branches/ros-csrss/win32ss/user/consrv/lang/de-DE.rc [iso-8859-1] Fri Feb 1 23:36:23 2013 @@ -19,5 +19,5 @@ IDS_SCROLLUP "Nach oben scrollen" IDS_SCROLLDOWN "Nach unten scrollen" - IDS_COMMAND_PROMPT "Eingabeaufforderung" + IDS_CONSOLE_TITLE "ReactOS Console" END Modified: branches/ros-csrss/win32ss/user/consrv/lang/el-GR.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-csrss/win32ss/user/consrv/l…
============================================================================== --- branches/ros-csrss/win32ss/user/consrv/lang/el-GR.rc [iso-8859-1] (original) +++ branches/ros-csrss/win32ss/user/consrv/lang/el-GR.rc [iso-8859-1] Fri Feb 1 23:36:23 2013 @@ -19,5 +19,5 @@ IDS_SCROLLUP "Êýëéóç ðÜíù" IDS_SCROLLDOWN "Êýëéóç êÜôù" - IDS_COMMAND_PROMPT "Command Prompt" + IDS_CONSOLE_TITLE "ReactOS Console" END Modified: branches/ros-csrss/win32ss/user/consrv/lang/en-US.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-csrss/win32ss/user/consrv/l…
============================================================================== --- branches/ros-csrss/win32ss/user/consrv/lang/en-US.rc [iso-8859-1] (original) +++ branches/ros-csrss/win32ss/user/consrv/lang/en-US.rc [iso-8859-1] Fri Feb 1 23:36:23 2013 @@ -19,5 +19,5 @@ IDS_SCROLLUP "Scroll up" IDS_SCROLLDOWN "Scroll down" - IDS_COMMAND_PROMPT "Command Prompt" + IDS_CONSOLE_TITLE "ReactOS Console" END Modified: branches/ros-csrss/win32ss/user/consrv/lang/es-ES.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-csrss/win32ss/user/consrv/l…
============================================================================== --- branches/ros-csrss/win32ss/user/consrv/lang/es-ES.rc [iso-8859-1] (original) +++ branches/ros-csrss/win32ss/user/consrv/lang/es-ES.rc [iso-8859-1] Fri Feb 1 23:36:23 2013 @@ -24,5 +24,5 @@ IDS_SCROLLUP "Desplazar arriba" IDS_SCROLLDOWN "Desplazar abajo" - IDS_COMMAND_PROMPT "Command Prompt" + IDS_CONSOLE_TITLE "ReactOS Console" END Modified: branches/ros-csrss/win32ss/user/consrv/lang/fr-FR.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-csrss/win32ss/user/consrv/l…
============================================================================== --- branches/ros-csrss/win32ss/user/consrv/lang/fr-FR.rc [iso-8859-1] (original) +++ branches/ros-csrss/win32ss/user/consrv/lang/fr-FR.rc [iso-8859-1] Fri Feb 1 23:36:23 2013 @@ -21,5 +21,5 @@ IDS_SCROLLUP "Défiler en haut" IDS_SCROLLDOWN "Défiler en bas" - IDS_COMMAND_PROMPT "Command Prompt" + IDS_CONSOLE_TITLE "ReactOS Console" END Modified: branches/ros-csrss/win32ss/user/consrv/lang/id-ID.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-csrss/win32ss/user/consrv/l…
============================================================================== --- branches/ros-csrss/win32ss/user/consrv/lang/id-ID.rc [iso-8859-1] (original) +++ branches/ros-csrss/win32ss/user/consrv/lang/id-ID.rc [iso-8859-1] Fri Feb 1 23:36:23 2013 @@ -19,5 +19,5 @@ IDS_SCROLLUP "Gulung Naik" IDS_SCROLLDOWN "Gulung Turun" - IDS_COMMAND_PROMPT "Command Prompt" + IDS_CONSOLE_TITLE "ReactOS Console" END Modified: branches/ros-csrss/win32ss/user/consrv/lang/it-IT.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-csrss/win32ss/user/consrv/l…
============================================================================== --- branches/ros-csrss/win32ss/user/consrv/lang/it-IT.rc [iso-8859-1] (original) +++ branches/ros-csrss/win32ss/user/consrv/lang/it-IT.rc [iso-8859-1] Fri Feb 1 23:36:23 2013 @@ -28,5 +28,5 @@ IDS_SCROLLUP "Scorri sù" IDS_SCROLLDOWN "Scorri giù" - IDS_COMMAND_PROMPT "Prompt dei commandi" + IDS_CONSOLE_TITLE "ReactOS Console" END Modified: branches/ros-csrss/win32ss/user/consrv/lang/ja-JP.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-csrss/win32ss/user/consrv/l…
============================================================================== --- branches/ros-csrss/win32ss/user/consrv/lang/ja-JP.rc [iso-8859-1] (original) +++ branches/ros-csrss/win32ss/user/consrv/lang/ja-JP.rc [iso-8859-1] Fri Feb 1 23:36:23 2013 @@ -19,5 +19,5 @@ IDS_SCROLLUP "ãÉXN[" IDS_SCROLLDOWN "ºÉXN[" - IDS_COMMAND_PROMPT "Command Prompt" + IDS_CONSOLE_TITLE "ReactOS Console" END Modified: branches/ros-csrss/win32ss/user/consrv/lang/no-NO.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-csrss/win32ss/user/consrv/l…
============================================================================== --- branches/ros-csrss/win32ss/user/consrv/lang/no-NO.rc [iso-8859-1] (original) +++ branches/ros-csrss/win32ss/user/consrv/lang/no-NO.rc [iso-8859-1] Fri Feb 1 23:36:23 2013 @@ -19,5 +19,5 @@ IDS_SCROLLUP "Rull opp" IDS_SCROLLDOWN "Rull ned" - IDS_COMMAND_PROMPT "Command Prompt" + IDS_CONSOLE_TITLE "ReactOS Console" END Modified: branches/ros-csrss/win32ss/user/consrv/lang/pl-PL.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-csrss/win32ss/user/consrv/l…
============================================================================== --- branches/ros-csrss/win32ss/user/consrv/lang/pl-PL.rc [iso-8859-1] (original) +++ branches/ros-csrss/win32ss/user/consrv/lang/pl-PL.rc [iso-8859-1] Fri Feb 1 23:36:23 2013 @@ -27,5 +27,5 @@ IDS_SCROLLUP "PrzewiÅ do góry" IDS_SCROLLDOWN "PrzewiÅ na dóÅ" - IDS_COMMAND_PROMPT "Wiersz polecenia" + IDS_CONSOLE_TITLE "ReactOS Console" END Modified: branches/ros-csrss/win32ss/user/consrv/lang/pt-BR.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-csrss/win32ss/user/consrv/l…
============================================================================== --- branches/ros-csrss/win32ss/user/consrv/lang/pt-BR.rc [iso-8859-1] (original) +++ branches/ros-csrss/win32ss/user/consrv/lang/pt-BR.rc [iso-8859-1] Fri Feb 1 23:36:23 2013 @@ -21,5 +21,5 @@ IDS_SCROLLUP "Scroll up" IDS_SCROLLDOWN "Scroll down" - IDS_COMMAND_PROMPT "Prompt de Comando" + IDS_CONSOLE_TITLE "ReactOS Console" END Modified: branches/ros-csrss/win32ss/user/consrv/lang/ro-RO.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-csrss/win32ss/user/consrv/l…
============================================================================== --- branches/ros-csrss/win32ss/user/consrv/lang/ro-RO.rc [iso-8859-1] (original) +++ branches/ros-csrss/win32ss/user/consrv/lang/ro-RO.rc [iso-8859-1] Fri Feb 1 23:36:23 2013 @@ -26,5 +26,5 @@ IDS_SCROLLUP "DeruleazÄ Ã®n sus" IDS_SCROLLDOWN "DeruleazÄ Ã®n jos" - IDS_COMMAND_PROMPT "Linie de comandÄ" + IDS_CONSOLE_TITLE "ReactOS Console" END Modified: branches/ros-csrss/win32ss/user/consrv/lang/ru-RU.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-csrss/win32ss/user/consrv/l…
============================================================================== --- branches/ros-csrss/win32ss/user/consrv/lang/ru-RU.rc [iso-8859-1] (original) +++ branches/ros-csrss/win32ss/user/consrv/lang/ru-RU.rc [iso-8859-1] Fri Feb 1 23:36:23 2013 @@ -19,5 +19,5 @@ IDS_SCROLLUP "ÐÑокÑÑÑиÑÑ Ð²Ð²ÐµÑÑ " IDS_SCROLLDOWN "Scroll Down" - IDS_COMMAND_PROMPT "Command Prompt" + IDS_CONSOLE_TITLE "ReactOS Console" END Modified: branches/ros-csrss/win32ss/user/consrv/lang/sk-SK.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-csrss/win32ss/user/consrv/l…
============================================================================== --- branches/ros-csrss/win32ss/user/consrv/lang/sk-SK.rc [iso-8859-1] (original) +++ branches/ros-csrss/win32ss/user/consrv/lang/sk-SK.rc [iso-8859-1] Fri Feb 1 23:36:23 2013 @@ -24,5 +24,5 @@ IDS_SCROLLUP "Rolova nahor" IDS_SCROLLDOWN "Rolova nadol" - IDS_COMMAND_PROMPT "Príkazový riadok" + IDS_CONSOLE_TITLE "ReactOS Console" END Modified: branches/ros-csrss/win32ss/user/consrv/lang/sv-SE.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-csrss/win32ss/user/consrv/l…
============================================================================== --- branches/ros-csrss/win32ss/user/consrv/lang/sv-SE.rc [iso-8859-1] (original) +++ branches/ros-csrss/win32ss/user/consrv/lang/sv-SE.rc [iso-8859-1] Fri Feb 1 23:36:23 2013 @@ -26,5 +26,5 @@ IDS_SCROLLUP "Skrolla upp" IDS_SCROLLDOWN "Skrolla ner" - IDS_COMMAND_PROMPT "Command Prompt" + IDS_CONSOLE_TITLE "ReactOS Console" END Modified: branches/ros-csrss/win32ss/user/consrv/lang/tr-TR.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-csrss/win32ss/user/consrv/l…
============================================================================== --- branches/ros-csrss/win32ss/user/consrv/lang/tr-TR.rc [iso-8859-1] (original) +++ branches/ros-csrss/win32ss/user/consrv/lang/tr-TR.rc [iso-8859-1] Fri Feb 1 23:36:23 2013 @@ -39,5 +39,5 @@ IDS_SCROLLUP "Yukarı yuvarla" IDS_SCROLLDOWN "AÅaÄı yuvarla" - IDS_COMMAND_PROMPT "Komut Ä°stemi" + IDS_CONSOLE_TITLE "ReactOS Console" END Modified: branches/ros-csrss/win32ss/user/consrv/lang/uk-UA.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-csrss/win32ss/user/consrv/l…
============================================================================== --- branches/ros-csrss/win32ss/user/consrv/lang/uk-UA.rc [iso-8859-1] (original) +++ branches/ros-csrss/win32ss/user/consrv/lang/uk-UA.rc [iso-8859-1] Fri Feb 1 23:36:23 2013 @@ -27,5 +27,5 @@ IDS_SCROLLUP "ÐÑокÑÑÑиÑи догоÑи" IDS_SCROLLDOWN "ÐÑокÑÑÑиÑи донизÑ" - IDS_COMMAND_PROMPT "Ðомандний ÑÑдок" + IDS_CONSOLE_TITLE "ReactOS Console" END Modified: branches/ros-csrss/win32ss/user/consrv/lang/zh-CN.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-csrss/win32ss/user/consrv/l…
============================================================================== --- branches/ros-csrss/win32ss/user/consrv/lang/zh-CN.rc [iso-8859-1] (original) +++ branches/ros-csrss/win32ss/user/consrv/lang/zh-CN.rc [iso-8859-1] Fri Feb 1 23:36:23 2013 @@ -19,5 +19,5 @@ IDS_SCROLLUP "ÏòÉϹö¶¯" IDS_SCROLLDOWN "ÏòϹö¶¯" - IDS_COMMAND_PROMPT "Command Prompt" + IDS_CONSOLE_TITLE "ReactOS Console" END Modified: branches/ros-csrss/win32ss/user/consrv/lang/zh-TW.rc URL:
http://svn.reactos.org/svn/reactos/branches/ros-csrss/win32ss/user/consrv/l…
============================================================================== --- branches/ros-csrss/win32ss/user/consrv/lang/zh-TW.rc [iso-8859-1] (original) +++ branches/ros-csrss/win32ss/user/consrv/lang/zh-TW.rc [iso-8859-1] Fri Feb 1 23:36:23 2013 @@ -19,5 +19,5 @@ IDS_SCROLLUP "¦V¤Wºu°Ê" IDS_SCROLLDOWN "¦V¤Uºu°Ê" - IDS_COMMAND_PROMPT "Command Prompt" + IDS_CONSOLE_TITLE "ReactOS Console" END Modified: branches/ros-csrss/win32ss/user/consrv/resource.h URL:
http://svn.reactos.org/svn/reactos/branches/ros-csrss/win32ss/user/consrv/r…
============================================================================== --- branches/ros-csrss/win32ss/user/consrv/resource.h [iso-8859-1] (original) +++ branches/ros-csrss/win32ss/user/consrv/resource.h [iso-8859-1] Fri Feb 1 23:36:23 2013 @@ -37,6 +37,6 @@ #define IDS_SCROLLUP 309 #define IDS_SCROLLDOWN 310 -#define IDS_COMMAND_PROMPT 500 +#define IDS_CONSOLE_TITLE 500 /* EOF */
11 years, 10 months
1
0
0
0
[ekohl] 58259: [SAMLIB] SamSetInformationUser: Build the LM password and calculate the LM password hash in the UserSetPasswordInformation case.
by ekohl@svn.reactos.org
Author: ekohl Date: Fri Feb 1 22:18:28 2013 New Revision: 58259 URL:
http://svn.reactos.org/svn/reactos?rev=58259&view=rev
Log: [SAMLIB] SamSetInformationUser: Build the LM password and calculate the LM password hash in the UserSetPasswordInformation case. Modified: trunk/reactos/dll/win32/samlib/samlib.c Modified: trunk/reactos/dll/win32/samlib/samlib.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/samlib/samlib.c?…
============================================================================== --- trunk/reactos/dll/win32/samlib/samlib.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/samlib/samlib.c [iso-8859-1] Fri Feb 1 22:18:28 2013 @@ -31,6 +31,10 @@ WINE_DEFAULT_DEBUG_CHANNEL(samlib); +NTSTATUS +WINAPI +SystemFunction006(LPCSTR password, + LPSTR hash); NTSTATUS WINAPI @@ -1602,7 +1606,8 @@ { PSAMPR_USER_SET_PASSWORD_INFORMATION PasswordBuffer; SAMPR_USER_INTERNAL1_INFORMATION Internal1Buffer; - + OEM_STRING LmPwdString; + CHAR LmPwdBuffer[15]; NTSTATUS Status; TRACE("SamSetInformationUser(%p %lu %p)\n", @@ -1623,6 +1628,25 @@ Internal1Buffer.NtPasswordPresent = TRUE; Internal1Buffer.LmPasswordPresent = FALSE; + + /* Build the LM password */ + LmPwdString.Length = 15; + LmPwdString.MaximumLength = 15; + LmPwdString.Buffer = LmPwdBuffer; + ZeroMemory(LmPwdString.Buffer, LmPwdString.MaximumLength); + + Status = RtlUpcaseUnicodeStringToOemString(&LmPwdString, + (PUNICODE_STRING)&PasswordBuffer->Password, + FALSE); + if (NT_SUCCESS(Status)) + { + /* Calculate the LM hash value of the password */ + Status = SystemFunction006(LmPwdString.Buffer, + (LPSTR)&Internal1Buffer.EncryptedLmOwfPassword); + if (NT_SUCCESS(Status)) + Internal1Buffer.LmPasswordPresent = TRUE; + } + Internal1Buffer.PasswordExpired = PasswordBuffer->PasswordExpired; RpcTryExcept
11 years, 10 months
1
0
0
0
[tfaber] 58258: [NTOSKRNL:MM] - More effective debugging CORE-6929
by tfaber@svn.reactos.org
Author: tfaber Date: Fri Feb 1 09:39:54 2013 New Revision: 58258 URL:
http://svn.reactos.org/svn/reactos?rev=58258&view=rev
Log: [NTOSKRNL:MM] - More effective debugging CORE-6929 Modified: trunk/reactos/ntoskrnl/mm/ARM3/expool.c trunk/reactos/ntoskrnl/mm/rmap.c Modified: trunk/reactos/ntoskrnl/mm/ARM3/expool.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/mm/ARM3/expool.c?…
============================================================================== --- trunk/reactos/ntoskrnl/mm/ARM3/expool.c [iso-8859-1] (original) +++ trunk/reactos/ntoskrnl/mm/ARM3/expool.c [iso-8859-1] Fri Feb 1 09:39:54 2013 @@ -572,8 +572,8 @@ // if (!TableEntry->Key) { - DPRINT1("Empty item reached in tracker table. Tag=0x%08lx, NumberOfBytes=%lu, PoolType=%d\n", - Key, (ULONG)NumberOfBytes, PoolType); + DPRINT1("Empty item reached in tracker table. Hash=0x%lx, TableMask=0x%lx, Tag=0x%08lx, NumberOfBytes=%lu, PoolType=%d\n", + Hash, TableMask, Key, (ULONG)NumberOfBytes, PoolType); ASSERT(Hash == TableMask); } Modified: trunk/reactos/ntoskrnl/mm/rmap.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/mm/rmap.c?rev=582…
============================================================================== --- trunk/reactos/ntoskrnl/mm/rmap.c [iso-8859-1] (original) +++ trunk/reactos/ntoskrnl/mm/rmap.c [iso-8859-1] Fri Feb 1 09:39:54 2013 @@ -27,6 +27,16 @@ /* FUNCTIONS ****************************************************************/ +_IRQL_requires_max_(DISPATCH_LEVEL) +static +VOID +NTAPI +RmapListFree( + _In_ __drv_freesMem(Mem) PVOID P) +{ + ExFreePoolWithTag(P, TAG_RMAP); +} + VOID INIT_FUNCTION NTAPI @@ -35,7 +45,7 @@ ExInitializeFastMutex(&RmapListLock); ExInitializeNPagedLookasideList (&RmapLookasideList, NULL, - NULL, + RmapListFree, 0, sizeof(MM_RMAP_ENTRY), TAG_RMAP,
11 years, 10 months
1
0
0
0
← Newer
1
...
10
11
12
13
Older →
Jump to page:
1
2
3
4
5
6
7
8
9
10
11
12
13
Results per page:
10
25
50
100
200