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
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
June 2017
----- 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
20 participants
526 discussions
Start a n
N
ew thread
[hbelusca] 75151: [USER.EXE]: Addendum to r75126: add a (dummy) version resource to USER.EXE so as to fix error 1812 "ERROR_RESOURCE_DATA_NOT_FOUND" encountered when starting the DirectX 9.0 instal...
by hbelusca@svn.reactos.org
Author: hbelusca Date: Tue Jun 20 16:44:40 2017 New Revision: 75151 URL:
http://svn.reactos.org/svn/reactos?rev=75151&view=rev
Log: [USER.EXE]: Addendum to r75126: add a (dummy) version resource to USER.EXE so as to fix error 1812 "ERROR_RESOURCE_DATA_NOT_FOUND" encountered when starting the DirectX 9.0 installer. From patch by Stas'M, thanks! CORE-13462 Added: trunk/reactos/subsystems/mvdm/wow16/user/user.rc (with props) Modified: trunk/reactos/subsystems/mvdm/wow16/user/CMakeLists.txt Modified: trunk/reactos/subsystems/mvdm/wow16/user/CMakeLists.txt URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/mvdm/wow16/user…
============================================================================== --- trunk/reactos/subsystems/mvdm/wow16/user/CMakeLists.txt [iso-8859-1] (original) +++ trunk/reactos/subsystems/mvdm/wow16/user/CMakeLists.txt [iso-8859-1] Tue Jun 20 16:44:40 2017 @@ -1,5 +1,5 @@ -add_executable(user user.c) +add_executable(user user.c user.rc) set_module_type(user win32gui ENTRYPOINT mainCRTStartup) add_importlibs(user msvcrt kernel32) add_cd_file(TARGET user DESTINATION reactos/system32 FOR all) Added: trunk/reactos/subsystems/mvdm/wow16/user/user.rc URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/mvdm/wow16/user…
============================================================================== --- trunk/reactos/subsystems/mvdm/wow16/user/user.rc (added) +++ trunk/reactos/subsystems/mvdm/wow16/user/user.rc [iso-8859-1] Tue Jun 20 16:44:40 2017 @@ -0,0 +1,5 @@ + +#define REACTOS_STR_FILE_DESCRIPTION "ReactOS WOW16 User-interface stub" +#define REACTOS_STR_INTERNAL_NAME "USER" +#define REACTOS_STR_ORIGINAL_FILENAME "USER.EXE" +#include <reactos/version.rc> Propchange: trunk/reactos/subsystems/mvdm/wow16/user/user.rc ------------------------------------------------------------------------------ svn:eol-style = native
7 years, 4 months
1
0
0
0
[tfaber] 75150: [NTOS:MM] - In MiDeletePte, check the ReferenceCount of transition PTEs, not the ShareCount (which is actually u2.Blink, since the page is in a modified/standby list). Also don't re...
by tfaber@svn.reactos.org
Author: tfaber Date: Tue Jun 20 15:51:47 2017 New Revision: 75150 URL:
http://svn.reactos.org/svn/reactos?rev=75150&view=rev
Log: [NTOS:MM] - In MiDeletePte, check the ReferenceCount of transition PTEs, not the ShareCount (which is actually u2.Blink, since the page is in a modified/standby list). Also don't reset the PageLocation, since MiDecrementReferenceCount expects it to be anything but ActiveAndValid. Fixes physical page leaks when using DPH, or other code that sets PAGE_NOACCESS. CORE-13311 #resolve Modified: trunk/reactos/ntoskrnl/mm/ARM3/virtual.c trunk/rostests/apitests/ntdll/NtProtectVirtualMemory.c Modified: trunk/reactos/ntoskrnl/mm/ARM3/virtual.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/mm/ARM3/virtual.c…
============================================================================== --- trunk/reactos/ntoskrnl/mm/ARM3/virtual.c [iso-8859-1] (original) +++ trunk/reactos/ntoskrnl/mm/ARM3/virtual.c [iso-8859-1] Tue Jun 20 15:51:47 2017 @@ -419,6 +419,9 @@ DPRINT("Pte %p is transitional!\n", PointerPte); + /* Make sure the saved PTE address is valid */ + ASSERT((PMMPTE)((ULONG_PTR)Pfn1->PteAddress & ~0x1) == PointerPte); + /* Destroy the PTE */ MI_ERASE_PTE(PointerPte); @@ -428,17 +431,14 @@ ASSERT(Pfn1->u3.e1.PrototypePte == 0); /* Make the page free. For prototypes, it will be made free when deleting the section object */ - if (Pfn1->u2.ShareCount == 0) - { - ASSERT(Pfn1->u3.e2.ReferenceCount == 0); - + if (Pfn1->u3.e2.ReferenceCount == 0) + { /* And it should be in standby or modified list */ ASSERT((Pfn1->u3.e1.PageLocation == ModifiedPageList) || (Pfn1->u3.e1.PageLocation == StandbyPageList)); - /* Unlink it and temporarily mark it as active */ + /* Unlink it and set its reference count to one */ MiUnlinkPageFromList(Pfn1); Pfn1->u3.e2.ReferenceCount++; - Pfn1->u3.e1.PageLocation = ActiveAndValid; /* This will put it back in free list and clean properly up */ MI_SET_PFN_DELETED(Pfn1); Modified: trunk/rostests/apitests/ntdll/NtProtectVirtualMemory.c URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/apitests/ntdll/NtProtectV…
============================================================================== --- trunk/rostests/apitests/ntdll/NtProtectVirtualMemory.c [iso-8859-1] (original) +++ trunk/rostests/apitests/ntdll/NtProtectVirtualMemory.c [iso-8859-1] Tue Jun 20 15:51:47 2017 @@ -2,6 +2,8 @@ * PROJECT: ReactOS API Tests * LICENSE: GPLv2+ - See COPYING in the top level directory * PURPOSE: Test for the NtProtectVirtualMemory API + * PROGRAMMERS: Jérôme Gardou <jerome.gardou(a)reactos.org> + * Thomas Faber <thomas.faber(a)reactos.org> */ #include <apitest.h> @@ -10,13 +12,15 @@ #include <ndk/rtlfuncs.h> #include <ndk/mmfuncs.h> -START_TEST(NtProtectVirtualMemory) +static +void +TestReadWrite(void) { ULONG* allocationStart = NULL; NTSTATUS status; SIZE_T allocationSize; ULONG oldProtection; - + /* Reserve a page */ allocationSize = PAGE_SIZE; status = NtAllocateVirtualMemory(NtCurrentProcess(), @@ -26,7 +30,7 @@ MEM_RESERVE, PAGE_NOACCESS); ok(NT_SUCCESS(status), "Reserving memory failed\n"); - + /* Commit the page (RW) */ status = NtAllocateVirtualMemory(NtCurrentProcess(), (void**)&allocationStart, @@ -35,19 +39,19 @@ MEM_COMMIT, PAGE_READWRITE); ok(NT_SUCCESS(status), "Commiting memory failed\n"); - + /* Try writing it */ StartSeh() { *allocationStart = 0xFF; } EndSeh(STATUS_SUCCESS); - + /* Try reading it */ StartSeh() { ok(*allocationStart == 0xFF, "Memory was not written\n"); } EndSeh(STATUS_SUCCESS); - + /* Set it as read only */ status = NtProtectVirtualMemory(NtCurrentProcess(), (void**)&allocationStart, @@ -56,19 +60,19 @@ &oldProtection); ok(NT_SUCCESS(status), "NtProtectVirtualMemory failed.\n"); ok(oldProtection == PAGE_READWRITE, "Expected PAGE_READWRITE, got %08lx.\n", oldProtection); - + /* Try writing it */ StartSeh() { *allocationStart = 0xAA; } EndSeh(STATUS_ACCESS_VIOLATION); - + /* Try reading it */ StartSeh() { ok(*allocationStart == 0xFF, "read-only memory were changed.\n"); } EndSeh(STATUS_SUCCESS); - + /* Set it as no access */ status = NtProtectVirtualMemory(NtCurrentProcess(), (void**)&allocationStart, @@ -77,13 +81,13 @@ &oldProtection); ok(NT_SUCCESS(status), "NtProtectVirtualMemory failed.\n"); ok(oldProtection == PAGE_READONLY, "Expected PAGE_READONLY, got %08lx.\n", oldProtection); - + /* Try writing it */ StartSeh() { *allocationStart = 0xAA; } EndSeh(STATUS_ACCESS_VIOLATION); - + /* Try reading it */ StartSeh() { @@ -110,7 +114,7 @@ { ok(*allocationStart == 0xFF, "Memory content was not preserved.\n"); } EndSeh(STATUS_SUCCESS); - + /* Free memory */ status = NtFreeVirtualMemory(NtCurrentProcess(), (void**)&allocationStart, @@ -118,3 +122,64 @@ MEM_RELEASE); ok(NT_SUCCESS(status), "Failed freeing memory.\n"); } + +/* Regression test for CORE-13311 */ +static +void +TestFreeNoAccess(void) +{ + PVOID Mem; + SIZE_T Size; + NTSTATUS Status; + ULONG Iteration, PageNumber; + PUCHAR Page; + ULONG OldProtection; + + for (Iteration = 0; Iteration < 50000; Iteration++) + { + Mem = NULL; + Size = 16 * PAGE_SIZE; + Status = NtAllocateVirtualMemory(NtCurrentProcess(), + &Mem, + 0, + &Size, + MEM_COMMIT, + PAGE_READWRITE); + ok_ntstatus(Status, STATUS_SUCCESS); + if (!NT_SUCCESS(Status)) + { + break; + } + + for (PageNumber = 0; PageNumber < 16; PageNumber++) + { + Page = Mem; + Page += PageNumber * PAGE_SIZE; + ok(*Page == 0, + "[%lu, %lu] Got non-zero memory. %x at %p\n", + Iteration, PageNumber, *Page, Page); + *Page = 123; + } + + Status = NtProtectVirtualMemory(NtCurrentProcess(), + &Mem, + &Size, + PAGE_NOACCESS, + &OldProtection); + ok_ntstatus(Status, STATUS_SUCCESS); + ok_hex(OldProtection, PAGE_READWRITE); + + Size = 0; + Status = NtFreeVirtualMemory(NtCurrentProcess(), + &Mem, + &Size, + MEM_RELEASE); + ok_ntstatus(Status, STATUS_SUCCESS); + } +} + +START_TEST(NtProtectVirtualMemory) +{ + TestReadWrite(); + TestFreeNoAccess(); +}
7 years, 4 months
1
0
0
0
[cfinck] 75149: That shouldn't have been committed in r75125. Thanks Thomas!
by cfinck@svn.reactos.org
Author: cfinck Date: Tue Jun 20 14:48:26 2017 New Revision: 75149 URL:
http://svn.reactos.org/svn/reactos?rev=75149&view=rev
Log: That shouldn't have been committed in r75125. Thanks Thomas! Modified: trunk/reactos/boot/bootdata/hivesys.inf Modified: trunk/reactos/boot/bootdata/hivesys.inf URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/boot/bootdata/hivesys.inf?…
============================================================================== --- trunk/reactos/boot/bootdata/hivesys.inf [iso-8859-1] (original) +++ trunk/reactos/boot/bootdata/hivesys.inf [iso-8859-1] Tue Jun 20 14:48:26 2017 @@ -2118,7 +2118,7 @@ HKLM,"SYSTEM\Setup","SystemSetupInProgress",0x00010001,0x00000001 ; Debug channels -HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\Environment","DEBUGCHANNEL",0x00020000,"+localspl" +;HKLM,"SYSTEM\CurrentControlSet\Control\Session Manager\Environment","DEBUGCHANNEL",0x00020000,"+ole,+rpc" ; Winsrv configuration HKLM,"SYSTEM\CurrentControlSet\Control\PriorityControl",,0x00000012
7 years, 4 months
1
0
0
0
[cfinck] 75148: [LOCALSPL] Add the missing root backslash to the symbolic link path. Fixes CORE-13457
by cfinck@svn.reactos.org
Author: cfinck Date: Tue Jun 20 06:08:30 2017 New Revision: 75148 URL:
http://svn.reactos.org/svn/reactos?rev=75148&view=rev
Log: [LOCALSPL] Add the missing root backslash to the symbolic link path. Fixes CORE-13457 Modified: trunk/reactos/win32ss/printing/providers/localspl/main.c Modified: trunk/reactos/win32ss/printing/providers/localspl/main.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/win32ss/printing/providers…
============================================================================== --- trunk/reactos/win32ss/printing/providers/localspl/main.c [iso-8859-1] (original) +++ trunk/reactos/win32ss/printing/providers/localspl/main.c [iso-8859-1] Tue Jun 20 06:08:30 2017 @@ -127,13 +127,13 @@ const DWORD cchPrintersPath = _countof(wszPrintersPath) - 1; const WCHAR wszSpoolPath[] = L"\\spool"; const DWORD cchSpoolPath = _countof(wszSpoolPath) - 1; - const WCHAR wszSymbolicLinkValue[] = L"REGISTRY\\MACHINE\\SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\Print\\Printers"; + const WCHAR wszSymbolicLinkValue[] = L"\\REGISTRY\\MACHINE\\SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\Print\\Printers"; const DWORD cbSymbolicLinkValue = sizeof(wszSymbolicLinkValue) - sizeof(WCHAR); BOOL bReturnValue = FALSE; DWORD cbData; DWORD dwErrorCode; - HKEY hKey; + HKEY hKey = NULL; // On startup, always create a volatile symbolic link in the registry if it doesn't exist yet. // "SYSTEM\CurrentControlSet\Control\Print\Printers" -> "SOFTWARE\Microsoft\Windows NT\CurrentVersion\Print\Printers"
7 years, 4 months
1
0
0
0
[hbelusca] 75147: [FILESYSTEMS]: Fix printf-like counted string specifiers.
by hbelusca@svn.reactos.org
Author: hbelusca Date: Tue Jun 20 00:45:07 2017 New Revision: 75147 URL:
http://svn.reactos.org/svn/reactos?rev=75147&view=rev
Log: [FILESYSTEMS]: Fix printf-like counted string specifiers. Modified: trunk/reactos/drivers/filesystems/cdfs/volinfo.c trunk/reactos/drivers/filesystems/fastfat/volume.c trunk/reactos/drivers/filesystems/ntfs/volinfo.c Modified: trunk/reactos/drivers/filesystems/cdfs/volinfo.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/filesystems/cdfs/v…
============================================================================== --- trunk/reactos/drivers/filesystems/cdfs/volinfo.c [iso-8859-1] (original) +++ trunk/reactos/drivers/filesystems/cdfs/volinfo.c [iso-8859-1] Tue Jun 20 00:45:07 2017 @@ -49,7 +49,7 @@ DPRINT("Required length %lu\n", (sizeof(FILE_FS_VOLUME_INFORMATION) + DeviceObject->Vpb->VolumeLabelLength)); DPRINT("LabelLength %hu\n", DeviceObject->Vpb->VolumeLabelLength); - DPRINT("Label %*.S\n", DeviceObject->Vpb->VolumeLabelLength / sizeof(WCHAR), DeviceObject->Vpb->VolumeLabel); + DPRINT("Label %.*S\n", DeviceObject->Vpb->VolumeLabelLength / sizeof(WCHAR), DeviceObject->Vpb->VolumeLabel); if (*BufferLength < sizeof(FILE_FS_VOLUME_INFORMATION)) return STATUS_INFO_LENGTH_MISMATCH; Modified: trunk/reactos/drivers/filesystems/fastfat/volume.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/filesystems/fastfa…
============================================================================== --- trunk/reactos/drivers/filesystems/fastfat/volume.c [iso-8859-1] (original) +++ trunk/reactos/drivers/filesystems/fastfat/volume.c [iso-8859-1] Tue Jun 20 00:45:07 2017 @@ -32,7 +32,7 @@ DPRINT("Required length %lu\n", FIELD_OFFSET(FILE_FS_VOLUME_INFORMATION, VolumeLabel) + DeviceObject->Vpb->VolumeLabelLength); DPRINT("LabelLength %hu\n", DeviceObject->Vpb->VolumeLabelLength); - DPRINT("Label %*.S\n", DeviceObject->Vpb->VolumeLabelLength / sizeof(WCHAR), DeviceObject->Vpb->VolumeLabel); + DPRINT("Label %.*S\n", DeviceObject->Vpb->VolumeLabelLength / sizeof(WCHAR), DeviceObject->Vpb->VolumeLabel); ASSERT(*BufferLength >= sizeof(FILE_FS_VOLUME_INFORMATION)); *BufferLength -= FIELD_OFFSET(FILE_FS_VOLUME_INFORMATION, VolumeLabel); Modified: trunk/reactos/drivers/filesystems/ntfs/volinfo.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/filesystems/ntfs/v…
============================================================================== --- trunk/reactos/drivers/filesystems/ntfs/volinfo.c [iso-8859-1] (original) +++ trunk/reactos/drivers/filesystems/ntfs/volinfo.c [iso-8859-1] Tue Jun 20 00:45:07 2017 @@ -115,7 +115,7 @@ sizeof(FILE_FS_VOLUME_INFORMATION) + DeviceObject->Vpb->VolumeLabelLength); DPRINT("LabelLength %hu\n", DeviceObject->Vpb->VolumeLabelLength); - DPRINT("Label %*.S\n", + DPRINT("Label %.*S\n", DeviceObject->Vpb->VolumeLabelLength / sizeof(WCHAR), DeviceObject->Vpb->VolumeLabel);
7 years, 4 months
1
0
0
0
[hbelusca] 75146: [NTOS:CM]: Simplify code by using suitable assertion macro.
by hbelusca@svn.reactos.org
Author: hbelusca Date: Mon Jun 19 23:18:42 2017 New Revision: 75146 URL:
http://svn.reactos.org/svn/reactos?rev=75146&view=rev
Log: [NTOS:CM]: Simplify code by using suitable assertion macro. Modified: trunk/reactos/ntoskrnl/config/cmdelay.c Modified: trunk/reactos/ntoskrnl/config/cmdelay.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/config/cmdelay.c?…
============================================================================== --- trunk/reactos/ntoskrnl/config/cmdelay.c [iso-8859-1] (original) +++ trunk/reactos/ntoskrnl/config/cmdelay.c [iso-8859-1] Mon Jun 19 23:18:42 2017 @@ -356,8 +356,7 @@ PAGED_CODE(); /* Sanity check */ - ASSERT((CmpIsKcbLockedExclusive(Kcb) == TRUE) || - (CmpTestRegistryLockExclusive() == TRUE)); + CMP_ASSERT_KCB_LOCK(Kcb); /* Make sure it's valid */ if (Kcb->DelayedCloseIndex != CmpDelayedCloseSize) ASSERT(FALSE); @@ -430,8 +429,7 @@ PAGED_CODE(); /* Sanity checks */ - ASSERT((CmpIsKcbLockedExclusive(Kcb) == TRUE) || - (CmpTestRegistryLockExclusive() == TRUE)); + CMP_ASSERT_KCB_LOCK(Kcb); if (Kcb->DelayedCloseIndex == CmpDelayedCloseSize) ASSERT(FALSE); /* Get the entry and lock the table */
7 years, 4 months
1
0
0
0
[jgardou] 75145: [DDK] - Use FORCEINLINE where appropriate
by jgardou@svn.reactos.org
Author: jgardou Date: Mon Jun 19 21:17:17 2017 New Revision: 75145 URL:
http://svn.reactos.org/svn/reactos?rev=75145&view=rev
Log: [DDK] - Use FORCEINLINE where appropriate Modified: trunk/reactos/sdk/include/ddk/fcb.h trunk/reactos/sdk/include/ddk/rxstruc.h Modified: trunk/reactos/sdk/include/ddk/fcb.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/sdk/include/ddk/fcb.h?rev=…
============================================================================== --- trunk/reactos/sdk/include/ddk/fcb.h [iso-8859-1] (original) +++ trunk/reactos/sdk/include/ddk/fcb.h [iso-8859-1] Mon Jun 19 21:17:17 2017 @@ -549,7 +549,7 @@ _In_ BOOLEAN RecursiveFinalize, _In_ BOOLEAN ForceFinalize); -extern INLINE +FORCEINLINE PUNICODE_STRING GET_ALREADY_PREFIXED_NAME( PMRX_SRV_OPEN SrvOpen, Modified: trunk/reactos/sdk/include/ddk/rxstruc.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/sdk/include/ddk/rxstruc.h?…
============================================================================== --- trunk/reactos/sdk/include/ddk/rxstruc.h [iso-8859-1] (original) +++ trunk/reactos/sdk/include/ddk/rxstruc.h [iso-8859-1] Mon Jun 19 21:17:17 2017 @@ -130,7 +130,7 @@ RDBSS_SCAVENGER RdbssScavengerInDeviceObject; } RDBSS_DEVICE_OBJECT, *PRDBSS_DEVICE_OBJECT; -extern INLINE +FORCEINLINE VOID NTAPI RxUnregisterMinirdr(
7 years, 4 months
1
0
0
0
[hbelusca] 75144: [NTOS]: Addendum to r75142: Use strsafe printf functions (suggested by Thomas).
by hbelusca@svn.reactos.org
Author: hbelusca Date: Mon Jun 19 20:37:36 2017 New Revision: 75144 URL:
http://svn.reactos.org/svn/reactos?rev=75144&view=rev
Log: [NTOS]: Addendum to r75142: Use strsafe printf functions (suggested by Thomas). Modified: trunk/reactos/ntoskrnl/config/cmsysini.c Modified: trunk/reactos/ntoskrnl/config/cmsysini.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/config/cmsysini.c…
============================================================================== --- trunk/reactos/ntoskrnl/config/cmsysini.c [iso-8859-1] (original) +++ trunk/reactos/ntoskrnl/config/cmsysini.c [iso-8859-1] Mon Jun 19 20:37:36 2017 @@ -621,9 +621,9 @@ ASSERT(Disposition == REG_CREATED_NEW_KEY); /* Initialize the target link name */ - swprintf(UnicodeBuffer, - L"\\Registry\\Machine\\System\\ControlSet%03ld", - ControlSet); + RtlStringCbPrintfW(UnicodeBuffer, sizeof(UnicodeBuffer), + L"\\Registry\\Machine\\System\\ControlSet%03ld", + ControlSet); RtlInitUnicodeString(&KeyName, UnicodeBuffer); /* Set the value */ @@ -696,7 +696,8 @@ } /* Build the profile name */ - swprintf(UnicodeBuffer, L"%04ld", HwProfile); + RtlStringCbPrintfW(UnicodeBuffer, sizeof(UnicodeBuffer), + L"%04ld", HwProfile); RtlInitUnicodeString(&KeyName, UnicodeBuffer); /* Open the associated key */ @@ -744,10 +745,10 @@ ASSERT(Disposition == REG_CREATED_NEW_KEY); /* Create the profile name */ - swprintf(UnicodeBuffer, - L"\\Registry\\Machine\\System\\CurrentControlSet\\" - L"Hardware Profiles\\%04ld", - HwProfile); + RtlStringCbPrintfW(UnicodeBuffer, sizeof(UnicodeBuffer), + L"\\Registry\\Machine\\System\\CurrentControlSet\\" + L"Hardware Profiles\\%04ld", + HwProfile); RtlInitUnicodeString(&KeyName, UnicodeBuffer); /* Set it */ @@ -2147,8 +2148,8 @@ HANDLE MicrosoftKeyHandle = NULL; HANDLE WindowsNtKeyHandle = NULL; HANDLE CurrentVersionKeyHandle = NULL; - WCHAR Buffer[128]; // Buffer large enough to contain a full ULONG in decimal representation, - // and the full 'CurrentType' string. + WCHAR Buffer[128]; // Buffer large enough to contain a full ULONG in decimal + // representation, and the full 'CurrentType' string. /* * Open the 'HKLM\Software\Microsoft\Windows NT\CurrentVersion' key @@ -2267,20 +2268,20 @@ /* Set the 'CurrentType' value */ RtlInitUnicodeString(&ValueName, L"CurrentType"); - - swprintf(Buffer, L"%s %s", + RtlStringCbPrintfW(Buffer, sizeof(Buffer), + L"%s %s", #ifdef CONFIG_SMP - L"Multiprocessor" + L"Multiprocessor" #else - L"Uniprocessor" + L"Uniprocessor" #endif - , + , #if (DBG == 1) - L"Checked" + L"Checked" #else - L"Free" + L"Free" #endif - ); + ); RtlInitUnicodeString(&ValueData, Buffer); NtSetValueKey(CurrentVersionKeyHandle, &ValueName,
7 years, 4 months
1
0
0
0
[hbelusca] 75143: [CMLIB][NTOS]: Use correct parameter type for the 4th parameter of CmpGetValueData(). [CMLIB]: Fix debug.h inclusion. [NTOS]: Use RtlCopyUnicodeString() to initialize the contents...
by hbelusca@svn.reactos.org
Author: hbelusca Date: Mon Jun 19 20:14:09 2017 New Revision: 75143 URL:
http://svn.reactos.org/svn/reactos?rev=75143&view=rev
Log: [CMLIB][NTOS]: Use correct parameter type for the 4th parameter of CmpGetValueData(). [CMLIB]: Fix debug.h inclusion. [NTOS]: Use RtlCopyUnicodeString() to initialize the contents of FullName. Modified: trunk/reactos/ntoskrnl/config/cminit.c trunk/reactos/ntoskrnl/config/cmparse.c trunk/reactos/sdk/lib/cmlib/cmkeydel.c trunk/reactos/sdk/lib/cmlib/cmse.c trunk/reactos/sdk/lib/cmlib/cmvalue.c Modified: trunk/reactos/ntoskrnl/config/cminit.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/config/cminit.c?r…
============================================================================== --- trunk/reactos/ntoskrnl/config/cminit.c [iso-8859-1] (original) +++ trunk/reactos/ntoskrnl/config/cminit.c [iso-8859-1] Mon Jun 19 20:14:09 2017 @@ -309,7 +309,7 @@ /* Build the full name */ FullName.Buffer = NameBuffer; FullName.MaximumLength = Length; - RtlAppendUnicodeStringToString(&FullName, BaseName); + RtlCopyUnicodeString(&FullName, BaseName); } else { Modified: trunk/reactos/ntoskrnl/config/cmparse.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/config/cmparse.c?…
============================================================================== --- trunk/reactos/ntoskrnl/config/cmparse.c [iso-8859-1] (original) +++ trunk/reactos/ntoskrnl/config/cmparse.c [iso-8859-1] Mon Jun 19 20:14:09 2017 @@ -112,7 +112,7 @@ if (!CmpGetValueData(Hive, LinkValue, &ValueLength, - (PVOID)&LinkName, + (PVOID*)&LinkName, &LinkNameAllocated, &CellToRelease)) { Modified: trunk/reactos/sdk/lib/cmlib/cmkeydel.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/sdk/lib/cmlib/cmkeydel.c?r…
============================================================================== --- trunk/reactos/sdk/lib/cmlib/cmkeydel.c [iso-8859-1] (original) +++ trunk/reactos/sdk/lib/cmlib/cmkeydel.c [iso-8859-1] Mon Jun 19 20:14:09 2017 @@ -10,7 +10,7 @@ #include "cmlib.h" #define NDEBUG -#include "debug.h" +#include <debug.h> /* FUNCTIONS *****************************************************************/ Modified: trunk/reactos/sdk/lib/cmlib/cmse.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/sdk/lib/cmlib/cmse.c?rev=7…
============================================================================== --- trunk/reactos/sdk/lib/cmlib/cmse.c [iso-8859-1] (original) +++ trunk/reactos/sdk/lib/cmlib/cmse.c [iso-8859-1] Mon Jun 19 20:14:09 2017 @@ -10,7 +10,7 @@ #include "cmlib.h" #define NDEBUG -#include "debug.h" +#include <debug.h> /* FUNCTIONS *****************************************************************/ Modified: trunk/reactos/sdk/lib/cmlib/cmvalue.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/sdk/lib/cmlib/cmvalue.c?re…
============================================================================== --- trunk/reactos/sdk/lib/cmlib/cmvalue.c [iso-8859-1] (original) +++ trunk/reactos/sdk/lib/cmlib/cmvalue.c [iso-8859-1] Mon Jun 19 20:14:09 2017 @@ -180,7 +180,7 @@ if (!CmpGetValueData(Hive, Value, Length, - (PVOID)&Buffer, + (PVOID*)&Buffer, &BufferAllocated, &CellToRelease)) {
7 years, 4 months
1
0
0
0
[hbelusca] 75142: [NTOS]: Fixes & improvements: - Fix a bug in CmpInitHiveFromFile(): correctly set the MaximumLength value of NewHive->FileFullPath; - Code simplification: no need to use temporary...
by hbelusca@svn.reactos.org
Author: hbelusca Date: Mon Jun 19 20:07:15 2017 New Revision: 75142 URL:
http://svn.reactos.org/svn/reactos?rev=75142&view=rev
Log: [NTOS]: Fixes & improvements: - Fix a bug in CmpInitHiveFromFile(): correctly set the MaximumLength value of NewHive->FileFullPath; - Code simplification: no need to use temporary ANSI string operations followed by UNICODE conversion, when one can do the same thing directly in UNICODE. - Use NULL for NULL handles. Modified: trunk/reactos/ntoskrnl/config/cmsysini.c Modified: trunk/reactos/ntoskrnl/config/cmsysini.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/config/cmsysini.c…
============================================================================== --- trunk/reactos/ntoskrnl/config/cmsysini.c [iso-8859-1] (original) +++ trunk/reactos/ntoskrnl/config/cmsysini.c [iso-8859-1] Mon Jun 19 20:07:15 2017 @@ -384,7 +384,7 @@ HiveName->Buffer, HiveName->Length); NewHive->FileFullPath.Length = HiveName->Length; - NewHive->FileFullPath.MaximumLength = HiveName->MaximumLength; + NewHive->FileFullPath.MaximumLength = HiveName->Length; } /* Return success */ @@ -529,12 +529,10 @@ OBJECT_ATTRIBUTES ObjectAttributes; CHAR ValueInfoBuffer[128]; PKEY_VALUE_FULL_INFORMATION ValueInfo; - CHAR Buffer[128]; WCHAR UnicodeBuffer[128]; HANDLE SelectHandle, KeyHandle, ConfigHandle = NULL, ProfileHandle = NULL; HANDLE ParentHandle = NULL; ULONG ControlSet, HwProfile; - ANSI_STRING TempString; NTSTATUS Status; ULONG ResultLength, Disposition; PLOADER_PARAMETER_EXTENSION LoaderExtension; @@ -622,16 +620,11 @@ /* Sanity check */ ASSERT(Disposition == REG_CREATED_NEW_KEY); - /* Initialize the symbolic link name */ - sprintf(Buffer, - "\\Registry\\Machine\\System\\ControlSet%03ld", - ControlSet); - RtlInitAnsiString(&TempString, Buffer); - - /* Create a Unicode string out of it */ - KeyName.MaximumLength = sizeof(UnicodeBuffer); - KeyName.Buffer = UnicodeBuffer; - Status = RtlAnsiStringToUnicodeString(&KeyName, &TempString, FALSE); + /* Initialize the target link name */ + swprintf(UnicodeBuffer, + L"\\Registry\\Machine\\System\\ControlSet%03ld", + ControlSet); + RtlInitUnicodeString(&KeyName, UnicodeBuffer); /* Set the value */ Status = NtSetValueKey(KeyHandle, @@ -655,7 +648,7 @@ if (!NT_SUCCESS(Status)) { /* Cleanup and exit */ - ConfigHandle = 0; + ConfigHandle = NULL; goto Cleanup; } @@ -698,21 +691,13 @@ if (!NT_SUCCESS(Status)) { /* Exit and clean up */ - ParentHandle = 0; + ParentHandle = NULL; goto Cleanup; } /* Build the profile name */ - sprintf(Buffer, "%04ld", HwProfile); - RtlInitAnsiString(&TempString, Buffer); - - /* Convert it to Unicode */ - KeyName.MaximumLength = sizeof(UnicodeBuffer); - KeyName.Buffer = UnicodeBuffer; - Status = RtlAnsiStringToUnicodeString(&KeyName, - &TempString, - FALSE); - ASSERT(Status == STATUS_SUCCESS); + swprintf(UnicodeBuffer, L"%04ld", HwProfile); + RtlInitUnicodeString(&KeyName, UnicodeBuffer); /* Open the associated key */ InitializeObjectAttributes(&ObjectAttributes, @@ -759,19 +744,11 @@ ASSERT(Disposition == REG_CREATED_NEW_KEY); /* Create the profile name */ - sprintf(Buffer, - "\\Registry\\Machine\\System\\CurrentControlSet\\" - "Hardware Profiles\\%04ld", + swprintf(UnicodeBuffer, + L"\\Registry\\Machine\\System\\CurrentControlSet\\" + L"Hardware Profiles\\%04ld", HwProfile); - RtlInitAnsiString(&TempString, Buffer); - - /* Convert it to Unicode */ - KeyName.MaximumLength = sizeof(UnicodeBuffer); - KeyName.Buffer = UnicodeBuffer; - Status = RtlAnsiStringToUnicodeString(&KeyName, - &TempString, - FALSE); - ASSERT(STATUS_SUCCESS == Status); + RtlInitUnicodeString(&KeyName, UnicodeBuffer); /* Set it */ Status = NtSetValueKey(KeyHandle,
7 years, 4 months
1
0
0
0
← Newer
1
...
8
9
10
11
12
13
14
...
53
Older →
Jump to page:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
Results per page:
10
25
50
100
200