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
2025
January
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
July 2005
----- 2025 -----
January 2025
----- 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
21 participants
563 discussions
Start a n
N
ew thread
[weiden] 16421: fix code that depends on GCC's void* pointer arithmetic extension
by weiden@svn.reactos.com
fix code that depends on GCC's void* pointer arithmetic extension Modified: trunk/reactos/ntoskrnl/cc/copy.c Modified: trunk/reactos/ntoskrnl/cc/pin.c Modified: trunk/reactos/ntoskrnl/ke/i386/exp.c Modified: trunk/reactos/ntoskrnl/mm/i386/page.c Modified: trunk/reactos/ntoskrnl/mm/region.c Modified: trunk/reactos/subsys/csrss/win32csr/conio.c Modified: trunk/reactos/subsys/csrss/win32csr/tuiconsole.c Modified: trunk/reactos/subsys/system/usetup/cabinet.c Modified: trunk/reactos/subsys/win32k/dib/dib16bpp.c Modified: trunk/reactos/subsys/win32k/dib/dib1bpp.c Modified: trunk/reactos/subsys/win32k/dib/dib24bpp.c Modified: trunk/reactos/subsys/win32k/dib/dib32bpp.c Modified: trunk/reactos/subsys/win32k/dib/dib4bpp.c Modified: trunk/reactos/subsys/win32k/dib/dib8bpp.c Modified: trunk/reactos/subsys/win32k/eng/bitblt.c Modified: trunk/reactos/subsys/win32k/ldr/loader.c Modified: trunk/reactos/subsys/win32k/ntuser/menu.c _____ Modified: trunk/reactos/ntoskrnl/cc/copy.c --- trunk/reactos/ntoskrnl/cc/copy.c 2005-07-05 00:24:36 UTC (rev 16420) +++ trunk/reactos/ntoskrnl/cc/copy.c 2005-07-05 00:57:47 UTC (rev 16421) @@ -89,15 +89,9 @@ { TempLength = min(Bcb->CacheSegmentSize, Length); memcpy(Buffer, current->BaseAddress, TempLength); -#if defined(__GNUC__) - Buffer += TempLength; -#else - { - char* pTemp = Buffer; - pTemp += TempLength; - Buffer = pTemp; - } -#endif + + Buffer = (PVOID)((ULONG_PTR)Buffer + TempLength); + Length = Length - TempLength; previous = current; current = current->NextInChain; @@ -180,15 +174,9 @@ current = current->NextInChain; TempLength = min(Bcb->CacheSegmentSize, Length); memcpy(Buffer, previous->BaseAddress, TempLength); -#if defined(__GNUC__) - Buffer += TempLength; -#else - { - char* pTemp = Buffer; - pTemp += TempLength; - Buffer = pTemp; - } -#endif + + Buffer = (PVOID)((ULONG_PTR)Buffer + TempLength); + Length = Length - TempLength; CcRosReleaseCacheSegment(Bcb, previous, TRUE, FALSE, FALSE); current_size += Bcb->CacheSegmentSize; @@ -393,15 +381,8 @@ ReadLength += TempLength; Length -= TempLength; ReadOffset += TempLength; -#if defined(__GNUC__) - Buffer += TempLength; -#else - { - char* pTemp = Buffer; - pTemp += TempLength; - Buffer = pTemp; - } -#endif + + Buffer = (PVOID)((ULONG_PTR)Buffer + TempLength); } IoStatus->Status = STATUS_SUCCESS; IoStatus->Information = ReadLength; @@ -488,15 +469,8 @@ Length -= TempLength; WriteOffset += TempLength; -#if defined(__GNUC__) - Buffer += TempLength; -#else - { - char* pTemp = Buffer; - pTemp += TempLength; - Buffer = pTemp; - } -#endif + + Buffer = (PVOID)((ULONG_PTR)Buffer + TempLength); } while (Length > 0) @@ -520,15 +494,8 @@ CcRosReleaseCacheSegment(Bcb, CacheSeg, TRUE, TRUE, FALSE); Length -= TempLength; WriteOffset += TempLength; -#if defined(__GNUC__) - Buffer += TempLength; -#else - { - char* pTemp = Buffer; - pTemp += TempLength; - Buffer = pTemp; - } -#endif + + Buffer = (PVOID)((ULONG_PTR)Buffer + TempLength); } return(TRUE); } _____ Modified: trunk/reactos/ntoskrnl/cc/pin.c --- trunk/reactos/ntoskrnl/cc/pin.c 2005-07-05 00:24:36 UTC (rev 16420) +++ trunk/reactos/ntoskrnl/cc/pin.c 2005-07-05 00:57:47 UTC (rev 16421) @@ -78,15 +78,8 @@ return(FALSE); } } -#if defined(__GNUC__) - *pBuffer += ReadOffset % Bcb->CacheSegmentSize; -#else - { - char* pTemp = *pBuffer; - pTemp += ReadOffset % Bcb->CacheSegmentSize; - *pBuffer = pTemp; - } -#endif + + *pBuffer = (PVOID)((ULONG_PTR)(*pBuffer) + (ReadOffset % Bcb->CacheSegmentSize)); iBcb = ExAllocateFromNPagedLookasideList(&iBcbLookasideList); if (iBcb == NULL) { _____ Modified: trunk/reactos/ntoskrnl/ke/i386/exp.c --- trunk/reactos/ntoskrnl/ke/i386/exp.c 2005-07-05 00:24:36 UTC (rev 16420) +++ trunk/reactos/ntoskrnl/ke/i386/exp.c 2005-07-05 00:57:47 UTC (rev 16421) @@ -729,7 +729,7 @@ } StackBase = Frame; - StackEnd = mbi.BaseAddress + mbi.RegionSize; + StackEnd = (PULONG)((ULONG_PTR)mbi.BaseAddress + mbi.RegionSize); while ( Frame >= StackBase && Frame < StackEnd ) { @@ -786,7 +786,7 @@ } StackBase = Frame; - StackEnd = mbi.BaseAddress + mbi.RegionSize; + StackEnd = (PULONG)((ULONG_PTR)mbi.BaseAddress + mbi.RegionSize); while ( Frame >= StackBase && Frame < StackEnd && i++ < FrameCount ) { @@ -838,7 +838,7 @@ } StackBase = Frame; - StackEnd = mbi.BaseAddress + mbi.RegionSize; + StackEnd = (PULONG)((ULONG_PTR)mbi.BaseAddress + mbi.RegionSize); while ( Count < FrameCount && Frame >= StackBase && Frame < StackEnd ) { _____ Modified: trunk/reactos/ntoskrnl/mm/i386/page.c --- trunk/reactos/ntoskrnl/mm/i386/page.c 2005-07-05 00:24:36 UTC (rev 16420) +++ trunk/reactos/ntoskrnl/mm/i386/page.c 2005-07-05 00:57:47 UTC (rev 16421) @@ -502,7 +502,7 @@ DPRINT("MmGetPageTableForProcessForPAE(%x %x %d)\n", Process, Address, Create); - if (Address >= (PVOID)PAGETABLE_MAP && Address < (PVOID)PAGETABLE_MAP + 0x800000) + if (Address >= (PVOID)PAGETABLE_MAP && Address < (PVOID)((ULONG_PTR)PAGETABLE_MAP + 0x800000)) { KEBUGCHECK(0); } @@ -1500,7 +1500,7 @@ ULONGLONG Pte; oldPdeOffset = PAE_ADDR_TO_PDE_OFFSET(Addr) + 1; - for (i = 0; i < PageCount; i++, Addr += PAGE_SIZE) + for (i = 0; i < PageCount; i++, Addr = (PVOID)((ULONG_PTR)Addr + PAGE_SIZE)) { if (!(Attributes & PA_PRESENT) && Pages[i] != 0) { @@ -1550,7 +1550,7 @@ } Pt--; - for (i = 0; i < PageCount; i++, Addr += PAGE_SIZE) + for (i = 0; i < PageCount; i++, Addr = (PVOID)((ULONG_PTR)Addr + PAGE_SIZE)) { if (!(Attributes & PA_PRESENT) && Pages[i] != 0) { @@ -1746,7 +1746,7 @@ PULONGLONG Pt = NULL; oldPdeOffset = PAE_ADDR_TO_PDE_OFFSET(Addr) + 1; - for (i = 0; i < PageCount; i++, Addr += PAGE_SIZE) + for (i = 0; i < PageCount; i++, Addr = (PVOID)((ULONG_PTR)Addr + PAGE_SIZE)) { if (!(Attributes & PA_PRESENT) && Pages[i] != 0) { @@ -1815,7 +1815,7 @@ PULONG Pt = NULL; ULONG Pte; oldPdeOffset = ADDR_TO_PDE_OFFSET(Addr) + 1; - for (i = 0; i < PageCount; i++, Addr += PAGE_SIZE) + for (i = 0; i < PageCount; i++, Addr = (PVOID)((ULONG_PTR)Addr + PAGE_SIZE)) { if (!(Attributes & PA_PRESENT) && Pages[i] != 0) { @@ -2182,7 +2182,7 @@ } } } - Address = (PVOID)HYPERSPACE + i * PAGE_SIZE; + Address = (PVOID)((ULONG_PTR)HYPERSPACE + i * PAGE_SIZE); FLUSH_TLB_ONE(Address); return Address; } @@ -2244,7 +2244,7 @@ ULONGLONG ZeroPde = 0LL; ULONG i; - for (i = PAE_ADDR_TO_PDTE_OFFSET(Address); i <= PAE_ADDR_TO_PDTE_OFFSET(Address + Size); i++) + for (i = PAE_ADDR_TO_PDTE_OFFSET(Address); i <= PAE_ADDR_TO_PDTE_OFFSET((PVOID)((ULONG_PTR)Address + Size)); i++) { if (i == PAE_ADDR_TO_PDTE_OFFSET(Address)) { @@ -2254,9 +2254,9 @@ { StartOffset = 0; } - if (i == PAE_ADDR_TO_PDTE_OFFSET(Address + Size)) + if (i == PAE_ADDR_TO_PDTE_OFFSET((PVOID)((ULONG_PTR)Address + Size))) { - EndOffset = PAE_ADDR_TO_PDE_PAGE_OFFSET(Address + Size); + EndOffset = PAE_ADDR_TO_PDE_PAGE_OFFSET((PVOID)((ULONG_PTR)Address + Size)); } else { @@ -2288,7 +2288,7 @@ { PULONG Pde; StartOffset = ADDR_TO_PDE_OFFSET(Address); - EndOffset = ADDR_TO_PDE_OFFSET(Address + Size); + EndOffset = ADDR_TO_PDE_OFFSET((PVOID)((ULONG_PTR)Address + Size)); if (Process != NULL && Process != PsGetCurrentProcess()) { _____ Modified: trunk/reactos/ntoskrnl/mm/region.c --- trunk/reactos/ntoskrnl/mm/region.c 2005-07-05 00:24:36 UTC (rev 16420) +++ trunk/reactos/ntoskrnl/mm/region.c 2005-07-05 00:57:47 UTC (rev 16421) @@ -170,16 +170,8 @@ CurrentRegion->Type, CurrentRegion->Protect, NewType, NewProtect); } -#if defined(__GNUC__) - CurrentBaseAddress += CurrentRegion->Length; -#else - { - char* pTemp = CurrentBaseAddress; - pTemp += CurrentRegion->Length; - CurrentBaseAddress = pTemp; - } -#endif + CurrentBaseAddress = (PVOID)((ULONG_PTR)CurrentBaseAddress + CurrentRegion->Length); NewRegion->Length += CurrentRegion->Length; RemainingLength -= CurrentRegion->Length; CurrentEntry = CurrentEntry->Flink; @@ -283,18 +275,9 @@ } current_entry = current_entry->Flink; -#if defined(__GNUC__) - StartAddress += current->Length; -#else + StartAddress = (PVOID)((ULONG_PTR)StartAddress + current->Length); - { - char* pTemp = StartAddress; - pTemp += current->Length; - StartAddress = pTemp; - } -#endif - } return(NULL); } _____ Modified: trunk/reactos/subsys/csrss/win32csr/conio.c --- trunk/reactos/subsys/csrss/win32csr/conio.c 2005-07-05 00:24:36 UTC (rev 16420) +++ trunk/reactos/subsys/csrss/win32csr/conio.c 2005-07-05 00:57:47 UTC (rev 16421) @@ -2273,8 +2273,8 @@ BufferCoord = Request->Data.WriteConsoleOutputRequest.BufferCoord; CharInfo = Request->Data.WriteConsoleOutputRequest.CharInfo; if (((PVOID)CharInfo < ProcessData->CsrSectionViewBase) || - (((PVOID)CharInfo + PSize) > - (ProcessData->CsrSectionViewBase + ProcessData->CsrSectionViewSize))) + (((ULONG_PTR)CharInfo + PSize) > + ((ULONG_PTR)ProcessData->CsrSectionViewBase + ProcessData->CsrSectionViewSize))) { ConioUnlockScreenBuffer(Buff); ConioUnlockConsole(Console); @@ -2690,7 +2690,7 @@ Size = Length * sizeof(INPUT_RECORD); if (((PVOID)InputRecord < ProcessData->CsrSectionViewBase) - || (((PVOID)InputRecord + Size) > (ProcessData->CsrSectionViewBase + ProcessData->CsrSectionViewSize))) + || (((ULONG_PTR)InputRecord + Size) > ((ULONG_PTR)ProcessData->CsrSectionViewBase + ProcessData->CsrSectionViewSize))) { ConioUnlockConsole(Console); Request->Status = STATUS_ACCESS_VIOLATION; @@ -2776,7 +2776,7 @@ CodePage = ProcessData->Console->OutputCodePage; if (((PVOID)CharInfo < ProcessData->CsrSectionViewBase) - || (((PVOID)CharInfo + Size) > (ProcessData->CsrSectionViewBase + ProcessData->CsrSectionViewSize))) + || (((ULONG_PTR)CharInfo + Size) > ((ULONG_PTR)ProcessData->CsrSectionViewBase + ProcessData->CsrSectionViewSize))) { ConioUnlockScreenBuffer(Buff); Request->Status = STATUS_ACCESS_VIOLATION; @@ -2856,7 +2856,7 @@ Size = Length * sizeof(INPUT_RECORD); if (((PVOID)InputRecord < ProcessData->CsrSectionViewBase) - || (((PVOID)InputRecord + Size) > (ProcessData->CsrSectionViewBase + ProcessData->CsrSectionViewSize))) + || (((ULONG_PTR)InputRecord + Size) > ((ULONG_PTR)ProcessData->CsrSectionViewBase + ProcessData->CsrSectionViewSize))) { ConioUnlockConsole(Console); Request->Status = STATUS_ACCESS_VIOLATION; _____ Modified: trunk/reactos/subsys/csrss/win32csr/tuiconsole.c --- trunk/reactos/subsys/csrss/win32csr/tuiconsole.c 2005-07-05 00:24:36 UTC (rev 16420) +++ trunk/reactos/subsys/csrss/win32csr/tuiconsole.c 2005-07-05 00:57:47 UTC (rev 16421) @@ -293,7 +293,7 @@ 0, sizeof(COORD) + Title.MaximumLength); pos = (COORD *)Buffer; - Title.Buffer = Buffer + sizeof( COORD ); + Title.Buffer = (PVOID)((ULONG_PTR)Buffer + sizeof( COORD )); RtlUnicodeStringToAnsiString(&Title, &SwapConsole->Title, FALSE); pos->Y = PhysicalConsoleSize.Y / 2; _____ Modified: trunk/reactos/subsys/system/usetup/cabinet.c --- trunk/reactos/subsys/system/usetup/cabinet.c 2005-07-05 00:24:36 UTC (rev 16420) +++ trunk/reactos/subsys/system/usetup/cabinet.c 2005-07-05 00:57:47 UTC (rev 16421) @@ -1033,7 +1033,7 @@ Status = CAB_STATUS_INVALID_CAB; goto UnmapDestFile; } - CurrentDestBuffer += OutputLength; // advance dest buffer by bytes produced + CurrentDestBuffer = (PVOID)((ULONG_PTR)CurrentDestBuffer + OutputLength); // advance dest buffer by bytes produced CurrentBuffer += InputLength; // advance src buffer by bytes consumed Size -= OutputLength; // reduce remaining file bytes by bytes produced RemainingBlock -= InputLength; // reduce remaining block size by bytes consumed _____ Modified: trunk/reactos/subsys/win32k/dib/dib16bpp.c --- trunk/reactos/subsys/win32k/dib/dib16bpp.c 2005-07-05 00:24:36 UTC (rev 16420) +++ trunk/reactos/subsys/win32k/dib/dib16bpp.c 2005-07-05 00:57:47 UTC (rev 16421) @@ -26,7 +26,7 @@ VOID DIB_16BPP_PutPixel(SURFOBJ *SurfObj, LONG x, LONG y, ULONG c) { - PBYTE byteaddr = SurfObj->pvScan0 + y * SurfObj->lDelta; + PBYTE byteaddr = (PBYTE)SurfObj->pvScan0 + y * SurfObj->lDelta; PWORD addr = (PWORD)byteaddr + x; *addr = (WORD)c; @@ -35,7 +35,7 @@ ULONG DIB_16BPP_GetPixel(SURFOBJ *SurfObj, LONG x, LONG y) { - PBYTE byteaddr = SurfObj->pvScan0 + y * SurfObj->lDelta; + PBYTE byteaddr = (PBYTE)SurfObj->pvScan0 + y * SurfObj->lDelta; PWORD addr = (PWORD)byteaddr + x; return (ULONG)(*addr); @@ -44,7 +44,7 @@ VOID DIB_16BPP_HLine(SURFOBJ *SurfObj, LONG x1, LONG x2, LONG y, ULONG c) { - PDWORD addr = (PDWORD)((PWORD)(SurfObj->pvScan0 + y * SurfObj->lDelta) + x1); + PDWORD addr = (PDWORD)((PWORD)((PBYTE)SurfObj->pvScan0 + y * SurfObj->lDelta) + x1); #ifdef _M_IX86 @@ -126,7 +126,7 @@ " jnz 1b" "\n\t" "2:" "\n\t" : /* no output */ - : "r"(SurfObj->pvScan0 + (y1 * SurfObj->lDelta) + (x * sizeof (WORD))), + : "r"((PBYTE)SurfObj->pvScan0 + (y1 * SurfObj->lDelta) + (x * sizeof (WORD))), "r"(SurfObj->lDelta), "r"(y2 - y1), "a"(c) : "cc", "memory", "%ecx"); #else @@ -150,7 +150,7 @@ LONG i, j, sx, sy, xColor, f1; PBYTE SourceBits, DestBits, SourceLine, DestLine; PBYTE SourceBits_4BPP, SourceLine_4BPP; - DestBits = BltInfo->DestSurface->pvScan0 + (BltInfo->DestRect.top * BltInfo->DestSurface->lDelta) + 2 * BltInfo->DestRect.left; + DestBits = (PBYTE)BltInfo->DestSurface->pvScan0 + (BltInfo->DestRect.top * BltInfo->DestSurface->lDelta) + 2 * BltInfo->DestRect.left; switch(BltInfo->SourceSurface->iBitmapFormat) { @@ -176,7 +176,7 @@ break; case BMF_4BPP: - SourceBits_4BPP = BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + (BltInfo->SourcePoint.x >> 1); + SourceBits_4BPP = (PBYTE)BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + (BltInfo->SourcePoint.x >> 1); for (j=BltInfo->DestRect.top; j<BltInfo->DestRect.bottom; j++) { @@ -198,7 +198,7 @@ break; case BMF_8BPP: - SourceLine = BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + BltInfo->SourcePoint.x; + SourceLine = (PBYTE)BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + BltInfo->SourcePoint.x; DestLine = DestBits; for (j = BltInfo->DestRect.top; j < BltInfo->DestRect.bottom; j++) @@ -223,7 +223,7 @@ { if (BltInfo->DestRect.top < BltInfo->SourcePoint.y) { - SourceBits = BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + 2 * BltInfo->SourcePoint.x; + SourceBits = (PBYTE)BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + 2 * BltInfo->SourcePoint.x; for (j = BltInfo->DestRect.top; j < BltInfo->DestRect.bottom; j++) { RtlMoveMemory(DestBits, SourceBits, 2 * (BltInfo->DestRect.right - BltInfo->DestRect.left)); @@ -233,8 +233,8 @@ } else { - SourceBits = BltInfo->SourceSurface->pvScan0 + ((BltInfo->SourcePoint.y + BltInfo->DestRect.bottom - BltInfo->DestRect.top - 1) * BltInfo->SourceSurface->lDelta) + 2 * BltInfo->SourcePoint.x; - DestBits = BltInfo->DestSurface->pvScan0 + ((BltInfo->DestRect.bottom - 1) * BltInfo->DestSurface->lDelta) + 2 * BltInfo->DestRect.left; + SourceBits = (PBYTE)BltInfo->SourceSurface->pvScan0 + ((BltInfo->SourcePoint.y + BltInfo->DestRect.bottom - BltInfo->DestRect.top - 1) * BltInfo->SourceSurface->lDelta) + 2 * BltInfo->SourcePoint.x; + DestBits = (PBYTE)BltInfo->DestSurface->pvScan0 + ((BltInfo->DestRect.bottom - 1) * BltInfo->DestSurface->lDelta) + 2 * BltInfo->DestRect.left; for (j = BltInfo->DestRect.bottom - 1; BltInfo->DestRect.top <= j; j--) { RtlMoveMemory(DestBits, SourceBits, 2 * (BltInfo->DestRect.right - BltInfo->DestRect.left)); @@ -247,7 +247,7 @@ { if (BltInfo->DestRect.top < BltInfo->SourcePoint.y) { - SourceLine = BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + 2 * BltInfo->SourcePoint.x; + SourceLine = (PBYTE)BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + 2 * BltInfo->SourcePoint.x; DestLine = DestBits; for (j = BltInfo->DestRect.top; j < BltInfo->DestRect.bottom; j++) { @@ -265,8 +265,8 @@ } else { - SourceLine = BltInfo->SourceSurface->pvScan0 + ((BltInfo->SourcePoint.y + BltInfo->DestRect.bottom - BltInfo->DestRect.top - 1) * BltInfo->SourceSurface->lDelta) + 2 * BltInfo->SourcePoint.x; - DestLine = BltInfo->DestSurface->pvScan0 + ((BltInfo->DestRect.bottom - 1) * BltInfo->DestSurface->lDelta) + 2 * BltInfo->DestRect.left; + SourceLine = (PBYTE)BltInfo->SourceSurface->pvScan0 + ((BltInfo->SourcePoint.y + BltInfo->DestRect.bottom - BltInfo->DestRect.top - 1) * BltInfo->SourceSurface->lDelta) + 2 * BltInfo->SourcePoint.x; + DestLine = (PBYTE)BltInfo->DestSurface->pvScan0 + ((BltInfo->DestRect.bottom - 1) * BltInfo->DestSurface->lDelta) + 2 * BltInfo->DestRect.left; for (j = BltInfo->DestRect.bottom - 1; BltInfo->DestRect.top <= j; j--) { SourceBits = SourceLine; @@ -285,7 +285,7 @@ break; case BMF_24BPP: - SourceLine = BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + 3 * BltInfo->SourcePoint.x; + SourceLine = (PBYTE)BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + 3 * BltInfo->SourcePoint.x; DestLine = DestBits; for (j = BltInfo->DestRect.top; j < BltInfo->DestRect.bottom; j++) @@ -309,7 +309,7 @@ break; case BMF_32BPP: - SourceLine = BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + 4 * BltInfo->SourcePoint.x; + SourceLine = (PBYTE)BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + 4 * BltInfo->SourcePoint.x; DestLine = DestBits; for (j = BltInfo->DestRect.top; j < BltInfo->DestRect.bottom; j++) @@ -356,7 +356,7 @@ ((BltInfo->DestRect.right - BltInfo->DestRect.left) & 0x1); SourceY = BltInfo->SourcePoint.y; DestBits = (PULONG)( - BltInfo->DestSurface->pvScan0 + + (PBYTE)BltInfo->DestSurface->pvScan0 + (BltInfo->DestRect.left << 1) + BltInfo->DestRect.top * BltInfo->DestSurface->lDelta); @@ -440,7 +440,7 @@ /* This is about 10% faster than the generic C code below */ ULONG delta = DestSurface->lDelta; ULONG width = (DestRect->right - DestRect->left) ; - PULONG pos = (PULONG) (DestSurface->pvScan0 + DestRect->top * delta + (DestRect->left<<1)); + PULONG pos = (PULONG) ((PBYTE)DestSurface->pvScan0 + DestRect->top * delta + (DestRect->left<<1)); color = (color&0xffff); /* If the color value is "abcd", put "abcdabcd" into color */ color += (color<<16); @@ -608,8 +608,8 @@ PIXEL *ScanLine, *ScanLineAhead; PIXEL *PrevSource = NULL; PIXEL *PrevSourceAhead = NULL; - PIXEL *Target = (PIXEL *) (DestSurf->pvScan0 + (DestRect->top * DestSurf->lDelta) + 2 * DestRect->left); - PIXEL *Source = (PIXEL *) (SourceSurf->pvScan0 + (SourceRect->top * SourceSurf->lDelta) + 2 * SourceRect->left); + PIXEL *Target = (PIXEL *) ((PBYTE)DestSurf->pvScan0 + (DestRect->top * DestSurf->lDelta) + 2 * DestRect->left); + PIXEL *Source = (PIXEL *) ((PBYTE)SourceSurf->pvScan0 + (SourceRect->top * SourceSurf->lDelta) + 2 * SourceRect->left); PSPAN ClipSpans; UINT ClipSpansCount; UINT SpanIndex; @@ -1406,7 +1406,7 @@ RoundedRight = DestRect->right - ((DestRect->right - DestRect->left) & 0x1); SourceY = SourcePoint->y; - DestBits = (ULONG*)(DestSurf->pvScan0 + + DestBits = (ULONG*)((PBYTE)DestSurf->pvScan0 + (DestRect->left << 1) + DestRect->top * DestSurf->lDelta); wd = DestSurf->lDelta - ((DestRect->right - DestRect->left) << 1); _____ Modified: trunk/reactos/subsys/win32k/dib/dib1bpp.c --- trunk/reactos/subsys/win32k/dib/dib1bpp.c 2005-07-05 00:24:36 UTC (rev 16420) +++ trunk/reactos/subsys/win32k/dib/dib1bpp.c 2005-07-05 00:57:47 UTC (rev 16421) @@ -25,7 +25,7 @@ VOID DIB_1BPP_PutPixel(SURFOBJ *SurfObj, LONG x, LONG y, ULONG c) { - PBYTE addr = SurfObj->pvScan0 + y * SurfObj->lDelta + (x >> 3); + PBYTE addr = (PBYTE)SurfObj->pvScan0 + y * SurfObj->lDelta + (x >> 3); if (0 == (c & 0x01)) *addr &= ~MASK1BPP(x); @@ -36,7 +36,7 @@ ULONG DIB_1BPP_GetPixel(SURFOBJ *SurfObj, LONG x, LONG y) { - PBYTE addr = SurfObj->pvScan0 + y * SurfObj->lDelta + (x >> 3); + PBYTE addr = (PBYTE)SurfObj->pvScan0 + y * SurfObj->lDelta + (x >> 3); return (*addr & MASK1BPP(x) ? 1 : 0); } @@ -378,7 +378,7 @@ DestX = BltInfo->DestRect.left; SourceX = BltInfo->SourcePoint.x; DestBits = (PULONG)( - BltInfo->DestSurface->pvScan0 + + (PBYTE)BltInfo->DestSurface->pvScan0 + (BltInfo->DestRect.left >> 3) + DestY * BltInfo->DestSurface->lDelta); _____ Modified: trunk/reactos/subsys/win32k/dib/dib24bpp.c --- trunk/reactos/subsys/win32k/dib/dib24bpp.c 2005-07-05 00:24:36 UTC (rev 16420) +++ trunk/reactos/subsys/win32k/dib/dib24bpp.c 2005-07-05 00:57:47 UTC (rev 16421) @@ -26,7 +26,7 @@ VOID DIB_24BPP_PutPixel(SURFOBJ *SurfObj, LONG x, LONG y, ULONG c) { - PBYTE addr = SurfObj->pvScan0 + (y * SurfObj->lDelta) + (x << 1) + x; + PBYTE addr = (PBYTE)SurfObj->pvScan0 + (y * SurfObj->lDelta) + (x << 1) + x; *(PUSHORT)(addr) = c & 0xFFFF; *(addr + 2) = (c >> 16) & 0xFF; } @@ -34,14 +34,14 @@ ULONG DIB_24BPP_GetPixel(SURFOBJ *SurfObj, LONG x, LONG y) { - PBYTE addr = SurfObj->pvScan0 + y * SurfObj->lDelta + (x << 1) + x; + PBYTE addr = (PBYTE)SurfObj->pvScan0 + y * SurfObj->lDelta + (x << 1) + x; return *(PUSHORT)(addr) + (*(addr + 2) << 16); } VOID DIB_24BPP_HLine(SURFOBJ *SurfObj, LONG x1, LONG x2, LONG y, ULONG c) { - PBYTE addr = SurfObj->pvScan0 + y * SurfObj->lDelta + (x1 << 1) + x1; + PBYTE addr = (PBYTE)SurfObj->pvScan0 + y * SurfObj->lDelta + (x1 << 1) + x1; ULONG Count = x2 - x1; #ifndef _M_IX86 ULONG MultiCount; @@ -141,7 +141,7 @@ VOID DIB_24BPP_VLine(SURFOBJ *SurfObj, LONG x, LONG y1, LONG y2, ULONG c) { - PBYTE addr = SurfObj->pvScan0 + y1 * SurfObj->lDelta + (x << 1) + x; + PBYTE addr = (PBYTE)SurfObj->pvScan0 + y1 * SurfObj->lDelta + (x << 1) + x; LONG lDelta = SurfObj->lDelta; c &= 0xFFFFFF; @@ -161,7 +161,7 @@ PBYTE SourceBits_4BPP, SourceLine_4BPP; PWORD SourceBits_16BPP, SourceLine_16BPP; - DestBits = BltInfo->DestSurface->pvScan0 + (BltInfo->DestRect.top * BltInfo->DestSurface->lDelta) + BltInfo->DestRect.left * 3; + DestBits = (PBYTE)BltInfo->DestSurface->pvScan0 + (BltInfo->DestRect.top * BltInfo->DestSurface->lDelta) + BltInfo->DestRect.left * 3; switch(BltInfo->SourceSurface->iBitmapFormat) { @@ -187,7 +187,7 @@ break; case BMF_4BPP: - SourceBits_4BPP = BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + (BltInfo->SourcePoint.x >> 1); + SourceBits_4BPP = (PBYTE)BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + (BltInfo->SourcePoint.x >> 1); for (j=BltInfo->DestRect.top; j<BltInfo->DestRect.bottom; j++) { @@ -213,7 +213,7 @@ break; case BMF_8BPP: - SourceLine = BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + BltInfo->SourcePoint.x; + SourceLine = (PBYTE)BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + BltInfo->SourcePoint.x; DestLine = DestBits; for (j = BltInfo->DestRect.top; j < BltInfo->DestRect.bottom; j++) @@ -236,7 +236,7 @@ break; case BMF_16BPP: - SourceBits_16BPP = BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + 2 * BltInfo->SourcePoint.x; + SourceBits_16BPP = (PWORD)((PBYTE)BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + 2 * BltInfo->SourcePoint.x); for (j=BltInfo->DestRect.top; j<BltInfo->DestRect.bottom; j++) { @@ -262,7 +262,7 @@ { if (BltInfo->DestRect.top < BltInfo->SourcePoint.y) { - SourceBits = BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + 3 * BltInfo->SourcePoint.x; + SourceBits = (PBYTE)BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + 3 * BltInfo->SourcePoint.x; for (j = BltInfo->DestRect.top; j < BltInfo->DestRect.bottom; j++) { RtlMoveMemory(DestBits, SourceBits, 3 * (BltInfo->DestRect.right - BltInfo->DestRect.left)); @@ -272,8 +272,8 @@ } else { - SourceBits = BltInfo->SourceSurface->pvScan0 + ((BltInfo->SourcePoint.y + BltInfo->DestRect.bottom - BltInfo->DestRect.top - 1) * BltInfo->SourceSurface->lDelta) + 3 * BltInfo->SourcePoint.x; - DestBits = BltInfo->DestSurface->pvScan0 + ((BltInfo->DestRect.bottom - 1) * BltInfo->DestSurface->lDelta) + 3 * BltInfo->DestRect.left; + SourceBits = (PBYTE)BltInfo->SourceSurface->pvScan0 + ((BltInfo->SourcePoint.y + BltInfo->DestRect.bottom - BltInfo->DestRect.top - 1) * BltInfo->SourceSurface->lDelta) + 3 * BltInfo->SourcePoint.x; + DestBits = (PBYTE)BltInfo->DestSurface->pvScan0 + ((BltInfo->DestRect.bottom - 1) * BltInfo->DestSurface->lDelta) + 3 * BltInfo->DestRect.left; for (j = BltInfo->DestRect.bottom - 1; BltInfo->DestRect.top <= j; j--) { RtlMoveMemory(DestBits, SourceBits, 3 * (BltInfo->DestRect.right - BltInfo->DestRect.left)); @@ -291,7 +291,7 @@ break; case BMF_32BPP: - SourceLine = BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + 4 * BltInfo->SourcePoint.x; + SourceLine = (PBYTE)BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + 4 * BltInfo->SourcePoint.x; DestLine = DestBits; for (j = BltInfo->DestRect.top; j < BltInfo->DestRect.bottom; j++) @@ -337,7 +337,7 @@ SourceY = BltInfo->SourcePoint.y; DestBits = (PBYTE)( - BltInfo->DestSurface->pvScan0 + + (PBYTE)BltInfo->DestSurface->pvScan0 + (BltInfo->DestRect.left << 1) + BltInfo->DestRect.left + BltInfo->DestRect.top * BltInfo->DestSurface->lDelta); @@ -397,7 +397,7 @@ ULONG DestY; #ifdef _M_IX86 - PBYTE xaddr = DestSurface->pvScan0 + DestRect->top * DestSurface->lDelta + (DestRect->left << 1) + DestRect->left; + PBYTE xaddr = (PBYTE)DestSurface->pvScan0 + DestRect->top * DestSurface->lDelta + (DestRect->left << 1) + DestRect->left; PBYTE addr; ULONG Count; ULONG xCount=DestRect->right - DestRect->left; @@ -1305,7 +1305,7 @@ BYTE *DestBits; SourceY = SourcePoint->y; - DestBits = (BYTE*)(DestSurf->pvScan0 + + DestBits = (BYTE*)((PBYTE)DestSurf->pvScan0 + (DestRect->left << 2) + DestRect->top * DestSurf->lDelta); wd = DestSurf->lDelta - ((DestRect->right - DestRect->left) << 2); _____ Modified: trunk/reactos/subsys/win32k/dib/dib32bpp.c --- trunk/reactos/subsys/win32k/dib/dib32bpp.c 2005-07-05 00:24:36 UTC (rev 16420) +++ trunk/reactos/subsys/win32k/dib/dib32bpp.c 2005-07-05 00:57:47 UTC (rev 16421) @@ -26,7 +26,7 @@ VOID DIB_32BPP_PutPixel(SURFOBJ *SurfObj, LONG x, LONG y, ULONG c) { - PBYTE byteaddr = SurfObj->pvScan0 + y * SurfObj->lDelta; + PBYTE byteaddr = (PBYTE)SurfObj->pvScan0 + y * SurfObj->lDelta; PDWORD addr = (PDWORD)byteaddr + x; *addr = c; @@ -35,7 +35,7 @@ ULONG DIB_32BPP_GetPixel(SURFOBJ *SurfObj, LONG x, LONG y) { - PBYTE byteaddr = SurfObj->pvScan0 + y * SurfObj->lDelta; + PBYTE byteaddr = (PBYTE)SurfObj->pvScan0 + y * SurfObj->lDelta; PDWORD addr = (PDWORD)byteaddr + x; return (ULONG)(*addr); @@ -47,7 +47,7 @@ DIB_32BPP_HLine(SURFOBJ *SurfObj, LONG x1, LONG x2, LONG y, ULONG c) { LONG cx = (x2 - x1) ; - PBYTE byteaddr = SurfObj->pvScan0 + y * SurfObj->lDelta; + PBYTE byteaddr = (PBYTE)SurfObj->pvScan0 + y * SurfObj->lDelta; PDWORD addr = (PDWORD)byteaddr + x1; __asm__ __volatile__ ( @@ -95,7 +95,7 @@ { - PBYTE byteaddr = SurfObj->pvScan0 + y1 * SurfObj->lDelta; + PBYTE byteaddr = (PBYTE)SurfObj->pvScan0 + y1 * SurfObj->lDelta; PDWORD addr = (PDWORD)byteaddr + x; LONG lDelta = SurfObj->lDelta >> 2; // >> 2 == / sizeof(DWORD) @@ -116,7 +116,7 @@ PBYTE SourceBits_4BPP, SourceLine_4BPP; PDWORD Source32, Dest32; - DestBits = BltInfo->DestSurface->pvScan0 + (BltInfo->DestRect.top * BltInfo->DestSurface->lDelta) + 4 * BltInfo->DestRect.left; + DestBits = (PBYTE)BltInfo->DestSurface->pvScan0 + (BltInfo->DestRect.top * BltInfo->DestSurface->lDelta) + 4 * BltInfo->DestRect.left; switch(BltInfo->SourceSurface->iBitmapFormat) { @@ -143,7 +143,7 @@ break; case BMF_4BPP: - SourceBits_4BPP = BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + (BltInfo->SourcePoint.x >> 1); + SourceBits_4BPP = (PBYTE)BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + (BltInfo->SourcePoint.x >> 1); for (j=BltInfo->DestRect.top; j<BltInfo->DestRect.bottom; j++) { @@ -165,7 +165,7 @@ break; case BMF_8BPP: - SourceLine = BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + BltInfo->SourcePoint.x; + SourceLine = (PBYTE)BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + BltInfo->SourcePoint.x; DestLine = DestBits; for (j = BltInfo->DestRect.top; j < BltInfo->DestRect.bottom; j++) @@ -187,7 +187,7 @@ break; case BMF_16BPP: - SourceLine = BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + 2 * BltInfo->SourcePoint.x; + SourceLine = (PBYTE)BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + 2 * BltInfo->SourcePoint.x; DestLine = DestBits; for (j = BltInfo->DestRect.top; j < BltInfo->DestRect.bottom; j++) @@ -209,7 +209,7 @@ break; case BMF_24BPP: - SourceLine = BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + 3 * BltInfo->SourcePoint.x; + SourceLine = (PBYTE)BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + 3 * BltInfo->SourcePoint.x; DestLine = DestBits; for (j = BltInfo->DestRect.top; j < BltInfo->DestRect.bottom; j++) @@ -237,7 +237,7 @@ { if (BltInfo->DestRect.top < BltInfo->SourcePoint.y) { - SourceBits = BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + 4 * BltInfo->SourcePoint.x; + SourceBits = (PBYTE)BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + 4 * BltInfo->SourcePoint.x; for (j = BltInfo->DestRect.top; j < BltInfo->DestRect.bottom; j++) { RtlMoveMemory(DestBits, SourceBits, 4 * (BltInfo->DestRect.right - BltInfo->DestRect.left)); @@ -247,8 +247,8 @@ } else { - SourceBits = BltInfo->SourceSurface->pvScan0 + ((BltInfo->SourcePoint.y + BltInfo->DestRect.bottom - BltInfo->DestRect.top - 1) * BltInfo->SourceSurface->lDelta) + 4 * BltInfo->SourcePoint.x; - DestBits = BltInfo->DestSurface->pvScan0 + ((BltInfo->DestRect.bottom - 1) * BltInfo->DestSurface->lDelta) + 4 * BltInfo->DestRect.left; + SourceBits = (PBYTE)BltInfo->SourceSurface->pvScan0 + ((BltInfo->SourcePoint.y + BltInfo->DestRect.bottom - BltInfo->DestRect.top - 1) * BltInfo->SourceSurface->lDelta) + 4 * BltInfo->SourcePoint.x; + DestBits = (PBYTE)BltInfo->DestSurface->pvScan0 + ((BltInfo->DestRect.bottom - 1) * BltInfo->DestSurface->lDelta) + 4 * BltInfo->DestRect.left; for (j = BltInfo->DestRect.bottom - 1; BltInfo->DestRect.top <= j; j--) { RtlMoveMemory(DestBits, SourceBits, 4 * (BltInfo->DestRect.right - BltInfo->DestRect.left)); @@ -261,7 +261,7 @@ { if (BltInfo->DestRect.top < BltInfo->SourcePoint.y) { - SourceBits = (BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + 4 * BltInfo->SourcePoint.x); + SourceBits = ((PBYTE)BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + 4 * BltInfo->SourcePoint.x); for (j = BltInfo->DestRect.top; j < BltInfo->DestRect.bottom; j++) { if (BltInfo->DestRect.left < BltInfo->SourcePoint.x) @@ -288,8 +288,8 @@ } else { - SourceBits = BltInfo->SourceSurface->pvScan0 + ((BltInfo->SourcePoint.y + BltInfo->DestRect.bottom - BltInfo->DestRect.top - 1) * BltInfo->SourceSurface->lDelta) + 4 * BltInfo->SourcePoint.x; - DestBits = BltInfo->DestSurface->pvScan0 + ((BltInfo->DestRect.bottom - 1) * BltInfo->DestSurface->lDelta) + 4 * BltInfo->DestRect.left; + SourceBits = (PBYTE)BltInfo->SourceSurface->pvScan0 + ((BltInfo->SourcePoint.y + BltInfo->DestRect.bottom - BltInfo->DestRect.top - 1) * BltInfo->SourceSurface->lDelta) + 4 * BltInfo->SourcePoint.x; + DestBits = (PBYTE)BltInfo->DestSurface->pvScan0 + ((BltInfo->DestRect.bottom - 1) * BltInfo->DestSurface->lDelta) + 4 * BltInfo->DestRect.left; for (j = BltInfo->DestRect.bottom - 1; BltInfo->DestRect.top <= j; j--) { if (BltInfo->DestRect.left < BltInfo->SourcePoint.x) @@ -363,7 +363,7 @@ UsesPattern = ROP4_USES_PATTERN(BltInfo->Rop4); SourceY = BltInfo->SourcePoint.y; - DestBits = (PULONG)(BltInfo->DestSurface->pvScan0 + (BltInfo->DestRect.left << 2) + + DestBits = (PULONG)((PBYTE)BltInfo->DestSurface->pvScan0 + (BltInfo->DestRect.left << 2) + BltInfo->DestRect.top * BltInfo->DestSurface->lDelta); Delta = BltInfo->DestSurface->lDelta - ((BltInfo->DestRect.right - BltInfo->DestRect.left) << 2); @@ -499,7 +499,7 @@ ULONG right = BltInfo->DestRect.right; ULONG delta = BltInfo->DestSurface->lDelta - ((BltInfo->DestRect.right - BltInfo->DestRect.left) <<2) ; - DestBits = (PULONG)(BltInfo->DestSurface->pvScan0 + (BltInfo->DestRect.left << 2) + + DestBits = (PULONG)((PBYTE)BltInfo->DestSurface->pvScan0 + (BltInfo->DestRect.left << 2) + BltInfo->DestRect.top * BltInfo->DestSurface->lDelta); for (DestY = BltInfo->DestRect.top; DestY < bottom; DestY++) @@ -539,7 +539,7 @@ ULONG right = BltInfo->DestRect.right; ULONG delta = BltInfo->DestSurface->lDelta - ((BltInfo->DestRect.right - BltInfo->DestRect.left) <<2) ; - DestBits = (PULONG)(BltInfo->DestSurface->pvScan0 + (BltInfo->DestRect.left << 2) + + DestBits = (PULONG)((PBYTE)BltInfo->DestSurface->pvScan0 + (BltInfo->DestRect.left << 2) + BltInfo->DestRect.top * BltInfo->DestSurface->lDelta); SourceY = BltInfo->SourcePoint.y; @@ -590,7 +590,7 @@ ULONG right = BltInfo->DestRect.right; ULONG delta = BltInfo->DestSurface->lDelta - ((BltInfo->DestRect.right - BltInfo->DestRect.left) <<2); - DestBits = (PULONG)(BltInfo->DestSurface->pvScan0 + (BltInfo->DestRect.left << 2) + + DestBits = (PULONG)((PBYTE)BltInfo->DestSurface->pvScan0 + (BltInfo->DestRect.left << 2) + BltInfo->DestRect.top * BltInfo->DestSurface->lDelta); SourceY = BltInfo->SourcePoint.y; @@ -640,7 +640,7 @@ ULONG right = BltInfo->DestRect.right; ULONG delta = BltInfo->DestSurface->lDelta - ((BltInfo->DestRect.right - BltInfo->DestRect.left) <<2) ; - DestBits = (PULONG)(BltInfo->DestSurface->pvScan0 + (BltInfo->DestRect.left << 2) + + DestBits = (PULONG)((PBYTE)BltInfo->DestSurface->pvScan0 + (BltInfo->DestRect.left << 2) + BltInfo->DestRect.top * BltInfo->DestSurface->lDelta); SourceY = BltInfo->SourcePoint.y; @@ -672,7 +672,7 @@ ULONG right = BltInfo->DestRect.right; ULONG delta = BltInfo->DestSurface->lDelta - ((BltInfo->DestRect.right - BltInfo->DestRect.left) <<2) ; - DestBits = (PULONG)(BltInfo->DestSurface->pvScan0 + (BltInfo->DestRect.left << 2) + + DestBits = (PULONG)((PBYTE)BltInfo->DestSurface->pvScan0 + (BltInfo->DestRect.left << 2) + BltInfo->DestRect.top * BltInfo->DestSurface->lDelta); SourceY = BltInfo->SourcePoint.y; @@ -814,8 +814,8 @@ PIXEL *ScanLine, *ScanLineAhead; PIXEL *PrevSource = NULL; PIXEL *PrevSourceAhead = NULL; - PIXEL *Target = (PIXEL *) (DestSurf->pvScan0 + (DestRect->top * DestSurf->lDelta) + 4 * DestRect->left); - PIXEL *Source = (PIXEL *) (SourceSurf->pvScan0 + (SourceRect->top * SourceSurf->lDelta) + 4 * SourceRect->left); + PIXEL *Target = (PIXEL *) ((PBYTE)DestSurf->pvScan0 + (DestRect->top * DestSurf->lDelta) + 4 * DestRect->left); + PIXEL *Source = (PIXEL *) ((PBYTE)SourceSurf->pvScan0 + (SourceRect->top * SourceSurf->lDelta) + 4 * SourceRect->left); PSPAN ClipSpans; UINT ClipSpansCount; UINT SpanIndex; @@ -1607,7 +1607,7 @@ ULONG *DestBits; SourceY = SourcePoint->y; - DestBits = (ULONG*)(DestSurf->pvScan0 + + DestBits = (ULONG*)((PBYTE)DestSurf->pvScan0 + (DestRect->left << 2) + DestRect->top * DestSurf->lDelta); wd = DestSurf->lDelta - ((DestRect->right - DestRect->left) << 2); _____ Modified: trunk/reactos/subsys/win32k/dib/dib4bpp.c --- trunk/reactos/subsys/win32k/dib/dib4bpp.c 2005-07-05 00:24:36 UTC (rev 16420) +++ trunk/reactos/subsys/win32k/dib/dib4bpp.c 2005-07-05 00:57:47 UTC (rev 16421) @@ -26,21 +26,21 @@ VOID DIB_4BPP_PutPixel(SURFOBJ *SurfObj, LONG x, LONG y, ULONG c) { - PBYTE addr = SurfObj->pvScan0 + (x>>1) + y * SurfObj->lDelta; + PBYTE addr = (PBYTE)SurfObj->pvScan0 + (x>>1) + y * SurfObj->lDelta; *addr = (*addr & notmask[x&1]) | (c << ((1-(x&1))<<2)); } ULONG DIB_4BPP_GetPixel(SURFOBJ *SurfObj, LONG x, LONG y) { - PBYTE addr = SurfObj->pvScan0 + (x>>1) + y * SurfObj->lDelta; + PBYTE addr = (PBYTE)SurfObj->pvScan0 + (x>>1) + y * SurfObj->lDelta; return (*addr >> ((1-(x&1))<<2)) & 0x0f; } VOID DIB_4BPP_HLine(SURFOBJ *SurfObj, LONG x1, LONG x2, LONG y, ULONG c) { - PBYTE addr = SurfObj->pvScan0 + (x1>>1) + y * SurfObj->lDelta; + PBYTE addr = (PBYTE)SurfObj->pvScan0 + (x1>>1) + y * SurfObj->lDelta; LONG cx = x1; while(cx < x2) { @@ -72,7 +72,7 @@ PBYTE DestBits, DestLine, SourceBits_8BPP, SourceLine_8BPP; PBYTE SourceBits, SourceLine; - DestBits = BltInfo->DestSurface->pvScan0 + + DestBits = (PBYTE)BltInfo->DestSurface->pvScan0 + (BltInfo->DestRect.left >> 1) + BltInfo->DestRect.top * BltInfo->DestSurface->lDelta; @@ -123,7 +123,7 @@ break; case BMF_8BPP: - SourceBits_8BPP = BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + BltInfo->SourcePoint.x; + SourceBits_8BPP = (PBYTE)BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + BltInfo->SourcePoint.x; for (j=BltInfo->DestRect.top; j<BltInfo->DestRect.bottom; j++) { @@ -145,7 +145,7 @@ break; case BMF_16BPP: - SourceLine = BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + 2 * BltInfo->SourcePoint.x; + SourceLine = (PBYTE)BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + 2 * BltInfo->SourcePoint.x; DestLine = DestBits; for (j = BltInfo->DestRect.top; j < BltInfo->DestRect.bottom; j++) @@ -169,7 +169,7 @@ break; case BMF_24BPP: - SourceBits_24BPP = BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + BltInfo->SourcePoint.x * 3; + SourceBits_24BPP = (PBYTE)BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + BltInfo->SourcePoint.x * 3; for (j=BltInfo->DestRect.top; j<BltInfo->DestRect.bottom; j++) { @@ -194,7 +194,7 @@ break; case BMF_32BPP: - SourceLine = BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + 4 * BltInfo->SourcePoint.x; + SourceLine = (PBYTE)BltInfo->SourceSurface->pvScan0 + (BltInfo->SourcePoint.y * BltInfo->SourceSurface->lDelta) + 4 * BltInfo->SourcePoint.x; DestLine = DestBits; for (j = BltInfo->DestRect.top; j < BltInfo->DestRect.bottom; j++) @@ -278,7 +278,7 @@ for (DestY = BltInfo->DestRect.top; DestY < BltInfo->DestRect.bottom; DestY++) { DestBits = (PULONG)( - BltInfo->DestSurface->pvScan0 + + (PBYTE)BltInfo->DestSurface->pvScan0 + (BltInfo->DestRect.left >> 1) + DestY * BltInfo->DestSurface->lDelta); SourceX = BltInfo->SourcePoint.x; _____ Modified: trunk/reactos/subsys/win32k/dib/dib8bpp.c --- trunk/reactos/subsys/win32k/dib/dib8bpp.c 2005-07-05 00:24:36 UTC (rev 16420) +++ trunk/reactos/subsys/win32k/dib/dib8bpp.c 2005-07-05 00:57:47 UTC (rev 16421) @@ -26,7 +26,7 @@ VOID DIB_8BPP_PutPixel(SURFOBJ *SurfObj, LONG x, LONG y, ULONG c) { - PBYTE byteaddr = SurfObj->pvScan0 + y * SurfObj->lDelta + x; + PBYTE byteaddr = (PBYTE)SurfObj->pvScan0 + y * SurfObj->lDelta + x; *byteaddr = c; } @@ -34,7 +34,7 @@ ULONG DIB_8BPP_GetPixel(SURFOBJ *SurfObj, LONG x, LONG y) { - PBYTE byteaddr = SurfObj->pvScan0 + y * SurfObj->lDelta + x; + PBYTE byteaddr = (PBYTE)SurfObj->pvScan0 + y * SurfObj->lDelta + x; return (ULONG)(*byteaddr); } @@ -42,13 +42,13 @@ VOID DIB_8BPP_HLine(SURFOBJ *SurfObj, LONG x1, LONG x2, LONG y, ULONG c) { - memset(SurfObj->pvScan0 + y * SurfObj->lDelta + x1, (BYTE) c, x2 - x1); + memset((PBYTE)SurfObj->pvScan0 + y * SurfObj->lDelta + x1, (BYTE) c, x2 - x1); } VOID DIB_8BPP_VLine(SURFOBJ *SurfObj, LONG x, LONG y1, LONG y2, ULONG c) { - PBYTE byteaddr = SurfObj->pvScan0 + y1 * SurfObj->lDelta; + PBYTE byteaddr = (PBYTE)SurfObj->pvScan0 + y1 * SurfObj->lDelta; PBYTE addr = byteaddr + x; LONG lDelta = SurfObj->lDelta; @@ -67,7 +67,7 @@ PBYTE SourceBits, DestBits, SourceLine, DestLine; PBYTE SourceBits_4BPP, SourceLine_4BPP; - DestBits = BltInfo->DestSurface->pvScan0 + (BltInfo->DestRect.top * BltInfo->DestSurface->lDelta) + BltInfo->DestRect.left; + DestBits = (PBYTE)BltInfo->DestSurface->pvScan0 + (BltInfo->DestRect.top * BltInfo->DestSurface->lDelta) + BltInfo->DestRect.left; switch(BltInfo->SourceSurface->iBitmapFormat) [truncated at 1000 lines; 175 more skipped]
19 years, 6 months
1
0
0
0
[weiden] 16420: fix code that depends on GCC's void* pointer arithmetic extension
by weiden@svn.reactos.com
fix code that depends on GCC's void* pointer arithmetic extension Modified: trunk/reactos/drivers/dd/ramdrv/ramdrv.c Modified: trunk/reactos/drivers/fs/cdfs/dirctl.c Modified: trunk/reactos/drivers/fs/cdfs/fcb.c Modified: trunk/reactos/drivers/fs/np/rw.c Modified: trunk/reactos/drivers/fs/ntfs/attrib.c Modified: trunk/reactos/drivers/fs/ntfs/mft.c Modified: trunk/reactos/drivers/lib/ip/network/receive.c Modified: trunk/reactos/drivers/lib/ip/transport/udp/udp.c Modified: trunk/reactos/drivers/net/dd/pcnet/pcnet.c Modified: trunk/reactos/drivers/net/dd/pcnet/pcnet.h Modified: trunk/reactos/drivers/net/ndis/ndis/io.c Modified: trunk/reactos/drivers/storage/atapi/atapi.c Modified: trunk/reactos/drivers/storage/cdrom/cdrom.c Modified: trunk/reactos/drivers/storage/scsiport/scsiport.c Modified: trunk/reactos/drivers/video/displays/vga/objects/bitblt.c Modified: trunk/reactos/drivers/video/displays/vga/vgavideo/vgavideo.c Modified: trunk/reactos/drivers/video/videoprt/videoprt.c Modified: trunk/reactos/include/reactos/helper.h Modified: trunk/reactos/lib/crt/search/lsearch.c Modified: trunk/reactos/lib/kernel32/file/find.c Modified: trunk/reactos/lib/kernel32/mem/global.c Modified: trunk/reactos/lib/kernel32/process/create.c Modified: trunk/reactos/lib/ntdll/csr/lpc.c Modified: trunk/reactos/lib/ntdll/ldr/startup.c Modified: trunk/reactos/lib/ntdll/ldr/utils.c Modified: trunk/reactos/lib/rosrtl/thread/i386/context.c Modified: trunk/reactos/lib/rtl/image.c Modified: trunk/reactos/lib/rtl/process.c Modified: trunk/reactos/lib/rtl/registry.c Modified: trunk/reactos/lib/user32/windows/bitmap.c _____ Modified: trunk/reactos/drivers/dd/ramdrv/ramdrv.c --- trunk/reactos/drivers/dd/ramdrv/ramdrv.c 2005-07-04 23:05:17 UTC (rev 16419) +++ trunk/reactos/drivers/dd/ramdrv/ramdrv.c 2005-07-05 00:24:36 UTC (rev 16420) @@ -63,9 +63,9 @@ Stk->Parameters.Read.Length = devext->Size - Stk->Parameters.Read.ByteOffset.u.LowPart; if( Stk->MajorFunction == IRP_MJ_READ ) RtlCopyMemory( MmGetSystemAddressForMdl( Irp->MdlAddress ), - devext->Buffer + Stk->Parameters.Read.ByteOffset.u.LowPart, + (PVOID)((ULONG_PTR)devext->Buffer + Stk->Parameters.Read.ByteOffset.u.LowPart), Stk->Parameters.Read.Length ); - else RtlCopyMemory( devext->Buffer + Stk->Parameters.Read.ByteOffset.u.LowPart, + else RtlCopyMemory( (PVOID)((ULONG_PTR)devext->Buffer + Stk->Parameters.Read.ByteOffset.u.LowPart), MmGetSystemAddressForMdl( Irp->MdlAddress ), Stk->Parameters.Read.Length ); Irp->IoStatus.Status = STATUS_SUCCESS; _____ Modified: trunk/reactos/drivers/fs/cdfs/dirctl.c --- trunk/reactos/drivers/fs/cdfs/dirctl.c 2005-07-04 23:05:17 UTC (rev 16419) +++ trunk/reactos/drivers/fs/cdfs/dirctl.c 2005-07-05 00:24:36 UTC (rev 16420) @@ -69,10 +69,10 @@ Record = (PDIR_RECORD)*Block; while (Index < *pIndex) { - (*Ptr) += Record->RecordLength; + (*Ptr) = (PVOID)((ULONG_PTR)(*Ptr) + Record->RecordLength); (*CurrentOffset) += Record->RecordLength; Record = *Ptr; - if (*Ptr - *Block >= BLOCKSIZE || Record->RecordLength == 0) + if ((ULONG_PTR)(*Ptr) - (ULONG_PTR)(*Block) >= BLOCKSIZE || Record->RecordLength == 0) { DPRINT("Map next sector\n"); CcUnpinData(*Context); @@ -96,7 +96,7 @@ } } - if (*Ptr - *Block >= BLOCKSIZE || Record->RecordLength == 0) + if ((ULONG_PTR)(*Ptr) - (ULONG_PTR)(*Block) >= BLOCKSIZE || Record->RecordLength == 0) { DPRINT("Map next sector\n"); CcUnpinData(*Context); @@ -259,11 +259,11 @@ return STATUS_UNSUCCESSFUL; } - Record = (PDIR_RECORD) (Block + Offset % BLOCKSIZE); + Record = (PDIR_RECORD) ((ULONG_PTR)Block + Offset % BLOCKSIZE); if (Offset) { Offset += Record->RecordLength; - Record = (PVOID)Record + Record->RecordLength; + Record = (PDIR_RECORD)((ULONG_PTR)Record + Record->RecordLength); } while(TRUE) @@ -356,7 +356,7 @@ } Offset += Record->RecordLength; - Record = (PVOID)Record + Record->RecordLength; + Record = (PDIR_RECORD)((ULONG_PTR)Record + Record->RecordLength); DirIndex++; } _____ Modified: trunk/reactos/drivers/fs/cdfs/fcb.c --- trunk/reactos/drivers/fs/cdfs/fcb.c 2005-07-04 23:05:17 UTC (rev 16419) +++ trunk/reactos/drivers/fs/cdfs/fcb.c 2005-07-05 00:24:36 UTC (rev 16420) @@ -580,7 +580,7 @@ Offset += Record->RecordLength; BlockOffset += Record->RecordLength; - Record = (PDIR_RECORD)(Block + BlockOffset); + Record = (PDIR_RECORD)((ULONG_PTR)Block + BlockOffset); if (BlockOffset >= BLOCKSIZE || Record->RecordLength == 0) { DPRINT("Map next sector\n"); @@ -597,7 +597,7 @@ DPRINT("CcMapData() failed\n"); return(STATUS_UNSUCCESSFUL); } - Record = (PDIR_RECORD)(Block + BlockOffset); + Record = (PDIR_RECORD)((ULONG_PTR)Block + BlockOffset); } if (Offset >= DirSize) _____ Modified: trunk/reactos/drivers/fs/np/rw.c --- trunk/reactos/drivers/fs/np/rw.c 2005-07-04 23:05:17 UTC (rev 16419) +++ trunk/reactos/drivers/fs/np/rw.c 2005-07-05 00:24:36 UTC (rev 16420) @@ -390,7 +390,7 @@ Information = Irp->IoStatus.Information; Length = IoGetCurrentIrpStackLocation(Irp)->Parameters.Read.Length; ASSERT (Information <= Length); - Buffer += Information; + Buffer = (PVOID)((ULONG_PTR)Buffer + Information); Length -= Information; Status = STATUS_SUCCESS; @@ -450,24 +450,24 @@ while (Length > 0 && Fcb->ReadDataAvailable > 0) { CopyLength = min(Fcb->ReadDataAvailable, Length); - if (Fcb->ReadPtr + CopyLength <= Fcb->Data + Fcb->MaxDataLength) + if ((ULONG_PTR)Fcb->ReadPtr + CopyLength <= (ULONG_PTR)Fcb->Data + Fcb->MaxDataLength) { memcpy(Buffer, Fcb->ReadPtr, CopyLength); - Fcb->ReadPtr += CopyLength; - if (Fcb->ReadPtr == Fcb->Data + Fcb->MaxDataLength) + Fcb->ReadPtr = (PVOID)((ULONG_PTR)Fcb->ReadPtr + CopyLength); + if (Fcb->ReadPtr == (PVOID)((ULONG_PTR)Fcb->Data + Fcb->MaxDataLength)) { Fcb->ReadPtr = Fcb->Data; } } else { - TempLength = Fcb->Data + Fcb->MaxDataLength - Fcb->ReadPtr; + TempLength = (ULONG)((ULONG_PTR)Fcb->Data + Fcb->MaxDataLength - (ULONG_PTR)Fcb->ReadPtr); memcpy(Buffer, Fcb->ReadPtr, TempLength); - memcpy(Buffer + TempLength, Fcb->Data, CopyLength - TempLength); - Fcb->ReadPtr = Fcb->Data + CopyLength - TempLength; + memcpy((PVOID)((ULONG_PTR)Buffer + TempLength), Fcb->Data, CopyLength - TempLength); + Fcb->ReadPtr = (PVOID)((ULONG_PTR)Fcb->Data + CopyLength - TempLength); } - Buffer += CopyLength; + Buffer = (PVOID)((ULONG_PTR)Buffer + CopyLength); Length -= CopyLength; Information += CopyLength; @@ -505,7 +505,7 @@ if (Fcb->ReadDataAvailable > Length) { - memmove(Fcb->Data, Fcb->Data + Length, + memmove(Fcb->Data, (PVOID)((ULONG_PTR)Fcb->Data + Length), Fcb->ReadDataAvailable - Length); Fcb->ReadDataAvailable -= Length; Status = STATUS_MORE_ENTRIES; @@ -694,21 +694,21 @@ while (Length > 0 && ReaderFcb->WriteQuotaAvailable > 0) { CopyLength = min(Length, ReaderFcb->WriteQuotaAvailable); - if (ReaderFcb->WritePtr + CopyLength <= ReaderFcb->Data + ReaderFcb->MaxDataLength) + if ((ULONG_PTR)ReaderFcb->WritePtr + CopyLength <= (ULONG_PTR)ReaderFcb->Data + ReaderFcb->MaxDataLength) { memcpy(ReaderFcb->WritePtr, Buffer, CopyLength); - ReaderFcb->WritePtr += CopyLength; - if (ReaderFcb->WritePtr == ReaderFcb->Data + ReaderFcb->MaxDataLength) + ReaderFcb->WritePtr = (PVOID)((ULONG_PTR)ReaderFcb->WritePtr + CopyLength); + if ((ULONG_PTR)ReaderFcb->WritePtr == (ULONG_PTR)ReaderFcb->Data + ReaderFcb->MaxDataLength) { ReaderFcb->WritePtr = ReaderFcb->Data; } } else { - TempLength = ReaderFcb->Data + ReaderFcb->MaxDataLength - ReaderFcb->WritePtr; + TempLength = (ULONG)((ULONG_PTR)ReaderFcb->Data + ReaderFcb->MaxDataLength - (ULONG_PTR)ReaderFcb->WritePtr); memcpy(ReaderFcb->WritePtr, Buffer, TempLength); memcpy(ReaderFcb->Data, Buffer + TempLength, CopyLength - TempLength); - ReaderFcb->WritePtr = ReaderFcb->Data + CopyLength - TempLength; + ReaderFcb->WritePtr = (PVOID)((ULONG_PTR)ReaderFcb->Data + CopyLength - TempLength); } Buffer += CopyLength; _____ Modified: trunk/reactos/drivers/fs/ntfs/attrib.c --- trunk/reactos/drivers/fs/ntfs/attrib.c 2005-07-04 23:05:17 UTC (rev 16419) +++ trunk/reactos/drivers/fs/ntfs/attrib.c 2005-07-05 00:24:36 UTC (rev 16420) @@ -125,7 +125,7 @@ ResAttr = (PRESIDENT_ATTRIBUTE)Attribute; // DbgPrint(" Length %lu Offset %hu ", ResAttr->ValueLength, ResAttr->ValueOffset); - FileNameAttr = (PFILENAME_ATTRIBUTE)((PVOID)ResAttr + ResAttr->ValueOffset); + FileNameAttr = (PFILENAME_ATTRIBUTE)((ULONG_PTR)ResAttr + ResAttr->ValueOffset); DbgPrint(" '%.*S' ", FileNameAttr->NameLength, FileNameAttr->Name); } @@ -141,7 +141,7 @@ ResAttr = (PRESIDENT_ATTRIBUTE)Attribute; // DbgPrint(" Length %lu Offset %hu ", ResAttr->ValueLength, ResAttr->ValueOffset); - VolumeName = (PWCHAR)((PVOID)ResAttr + ResAttr->ValueOffset); + VolumeName = (PWCHAR)((ULONG_PTR)ResAttr + ResAttr->ValueOffset); DbgPrint(" '%.*S' ", ResAttr->ValueLength / sizeof(WCHAR), VolumeName); } @@ -157,7 +157,7 @@ ResAttr = (PRESIDENT_ATTRIBUTE)Attribute; // DbgPrint(" Length %lu Offset %hu ", ResAttr->ValueLength, ResAttr->ValueOffset); - VolInfoAttr = (PVOLINFO_ATTRIBUTE)((PVOID)ResAttr + ResAttr->ValueOffset); + VolInfoAttr = (PVOLINFO_ATTRIBUTE)((ULONG_PTR)ResAttr + ResAttr->ValueOffset); DbgPrint(" NTFS Version %u.%u Flags 0x%04hx ", VolInfoAttr->MajorVersion, VolInfoAttr->MinorVersion, _____ Modified: trunk/reactos/drivers/fs/ntfs/mft.c --- trunk/reactos/drivers/fs/ntfs/mft.c 2005-07-04 23:05:17 UTC (rev 16419) +++ trunk/reactos/drivers/fs/ntfs/mft.c 2005-07-05 00:24:36 UTC (rev 16420) @@ -208,7 +208,7 @@ ULONG n = m > 0 ? (index & m) : 0; - memcpy(file, p + n * BytesPerFileRecord, BytesPerFileRecord); + memcpy(file, (PVOID)((ULONG_PTR)p + n * BytesPerFileRecord), BytesPerFileRecord); ExFreePool(p); @@ -290,7 +290,7 @@ VOID FixupUpdateSequenceArray(PFILE_RECORD_HEADER file) { - PUSHORT usa = (PUSHORT)((PVOID)file + file->Ntfs.UsaOffset); + PUSHORT usa = (PUSHORT)((ULONG_PTR)file + file->Ntfs.UsaOffset); PUSHORT sector = (PUSHORT)file; ULONG i; _____ Modified: trunk/reactos/drivers/lib/ip/network/receive.c --- trunk/reactos/drivers/lib/ip/network/receive.c 2005-07-04 23:05:17 UTC (rev 16419) +++ trunk/reactos/drivers/lib/ip/network/receive.c 2005-07-05 00:24:36 UTC (rev 16420) @@ -225,7 +225,7 @@ /* Copy the header into the buffer */ RtlCopyMemory(IPPacket->Header, &IPDR->IPv4Header, IPDR->HeaderSize); - Data = IPPacket->Header + IPDR->HeaderSize; + Data = (PVOID)((ULONG_PTR)IPPacket->Header + IPDR->HeaderSize); IPPacket->Data = Data; /* Copy data from all fragments into buffer */ _____ Modified: trunk/reactos/drivers/lib/ip/transport/udp/udp.c --- trunk/reactos/drivers/lib/ip/transport/udp/udp.c 2005-07-04 23:05:17 UTC (rev 16419) +++ trunk/reactos/drivers/lib/ip/transport/udp/udp.c 2005-07-05 00:24:36 UTC (rev 16420) @@ -44,7 +44,7 @@ sizeof(UDP_HEADER), (PVOID *)&UDPHeader ); /* Build UDP header */ - UDPHeader = (PUDP_HEADER)(IPPacket->Data - sizeof(UDP_HEADER)); + UDPHeader = (PUDP_HEADER)((ULONG_PTR)IPPacket->Data - sizeof(UDP_HEADER)); /* Port values are already big-endian values */ UDPHeader->SourcePort = LocalPort; UDPHeader->DestPort = RemotePort; _____ Modified: trunk/reactos/drivers/net/dd/pcnet/pcnet.c --- trunk/reactos/drivers/net/dd/pcnet/pcnet.c 2005-07-04 23:05:17 UTC (rev 16419) +++ trunk/reactos/drivers/net/dd/pcnet/pcnet.c 2005-07-05 00:24:36 UTC (rev 16420) @@ -564,7 +564,7 @@ NdisMDeregisterInterrupt(&Adapter->InterruptObject); /* deregister i/o port range */ - NdisMDeregisterIoPortRange(Adapter->MiniportAdapterHandle, Adapter->IoBaseAddress, NUMBER_OF_PORTS, Adapter->PortOffset); + NdisMDeregisterIoPortRange(Adapter->MiniportAdapterHandle, Adapter->IoBaseAddress, NUMBER_OF_PORTS, (PVOID)Adapter->PortOffset); /* free shared memory */ MiFreeSharedMemory(Adapter); @@ -852,8 +852,8 @@ } /* register an IO port range */ - Status = NdisMRegisterIoPortRange(&Adapter->PortOffset, Adapter->MiniportAdapterHandle, - Adapter->IoBaseAddress, NUMBER_OF_PORTS); + Status = NdisMRegisterIoPortRange((PVOID*)&Adapter->PortOffset, Adapter->MiniportAdapterHandle, + (UINT)Adapter->IoBaseAddress, NUMBER_OF_PORTS); if(Status != NDIS_STATUS_SUCCESS) { DPRINT1("NdisMRegisterIoPortRange failed: 0x%x\n", Status); @@ -914,7 +914,7 @@ NdisMFreeMapRegisters(Adapter->MiniportAdapterHandle); /* doesn't hurt to free if we never alloc'd? */ if(Adapter->PortOffset) - NdisMDeregisterIoPortRange(Adapter->MiniportAdapterHandle, Adapter->IoBaseAddress, NUMBER_OF_PORTS, Adapter->PortOffset); + NdisMDeregisterIoPortRange(Adapter->MiniportAdapterHandle, Adapter->IoBaseAddress, NUMBER_OF_PORTS, (PVOID)Adapter->PortOffset); if(InterruptRegistered) NdisMDeregisterInterrupt(&Adapter->InterruptObject); _____ Modified: trunk/reactos/drivers/net/dd/pcnet/pcnet.h --- trunk/reactos/drivers/net/dd/pcnet/pcnet.h 2005-07-04 23:05:17 UTC (rev 16419) +++ trunk/reactos/drivers/net/dd/pcnet/pcnet.h 2005-07-05 00:24:36 UTC (rev 16420) @@ -57,7 +57,7 @@ ULONG Flags; ULONG InterruptVector; ULONG IoBaseAddress; - PVOID PortOffset; + ULONG_PTR PortOffset; NDIS_MINIPORT_INTERRUPT InterruptObject; NDIS_MEDIA_STATE MediaState; NDIS_MINIPORT_TIMER MediaDetectionTimer; _____ Modified: trunk/reactos/drivers/net/ndis/ndis/io.c --- trunk/reactos/drivers/net/ndis/ndis/io.c 2005-07-04 23:05:17 UTC (rev 16419) +++ trunk/reactos/drivers/net/ndis/ndis/io.c 2005-07-05 00:24:36 UTC (rev 16420) @@ -487,7 +487,7 @@ */ { PLOGICAL_ADAPTER Adapter = 0; - VOID *CurrentVa; + PVOID CurrentVa; ULONG TotalLength; PHYSICAL_ADDRESS ReturnedAddress; UINT LoopCount = 0; @@ -514,7 +514,7 @@ PhysicalAddressArray[LoopCount].Length = Length; TotalLength -= Length; - CurrentVa += Length; + CurrentVa = (PVOID)((ULONG_PTR)CurrentVa + Length); LoopCount++; } _____ Modified: trunk/reactos/drivers/storage/atapi/atapi.c --- trunk/reactos/drivers/storage/atapi/atapi.c 2005-07-04 23:05:17 UTC (rev 16419) +++ trunk/reactos/drivers/storage/atapi/atapi.c 2005-07-05 00:24:36 UTC (rev 16420) @@ -3066,7 +3066,7 @@ DPRINT("AtapiInitDma()\n"); StartAddress = Srb->DataBuffer; - EndAddress = StartAddress + Srb->DataTransferLength; + EndAddress = (PVOID)((ULONG_PTR)StartAddress + Srb->DataTransferLength); DevExt->PRDCount = 0; while (StartAddress < EndAddress) @@ -3105,7 +3105,7 @@ return FALSE; } PhysicalAddress.u.LowPart += tmpLength; - StartAddress += tmpLength; + StartAddress = (PVOID)((ULONG_PTR)StartAddress + tmpLength); Length -= tmpLength; PRDEntry->PhysAddress = PhysicalAddress.u.LowPart; } @@ -3114,7 +3114,7 @@ PRDEntry->PhysAddress = PhysicalAddress.u.LowPart; PRDEntry->Length = tmpLength; PRDEntry++; - StartAddress += tmpLength; + StartAddress = (PVOID)((ULONG_PTR)StartAddress + tmpLength); PhysicalAddress.u.LowPart += tmpLength; Length -= tmpLength; } _____ Modified: trunk/reactos/drivers/storage/cdrom/cdrom.c --- trunk/reactos/drivers/storage/cdrom/cdrom.c 2005-07-04 23:05:17 UTC (rev 16419) +++ trunk/reactos/drivers/storage/cdrom/cdrom.c 2005-07-05 00:24:36 UTC (rev 16420) @@ -1485,10 +1485,10 @@ if (Retry == TRUE && (ULONG)OrigNextIrpStack->Parameters.Others.Argument1 > 0) { - DPRINT1 ("Try again (Retry count %lu)\n", + DPRINT1 ("Try again (Retry count 0x%p)\n", (ULONG)OrigNextIrpStack->Parameters.Others.Argument1); - (ULONG)OrigNextIrpStack->Parameters.Others.Argument1--; + OrigNextIrpStack->Parameters.Others.Argument1 = (PVOID)((ULONG_PTR)OrigNextIrpStack->Parameters.Others.Argument1 - 1); /* Release 'old' buffers */ ExFreePool (Srb->SenseInfoBuffer); _____ Modified: trunk/reactos/drivers/storage/scsiport/scsiport.c --- trunk/reactos/drivers/storage/scsiport/scsiport.c 2005-07-04 23:05:17 UTC (rev 16419) +++ trunk/reactos/drivers/storage/scsiport/scsiport.c 2005-07-05 00:24:36 UTC (rev 16420) @@ -478,7 +478,7 @@ } if (Srb == NULL) { - EndAddress = DeviceExtension->VirtualAddress + DeviceExtension->CommonBufferLength; + EndAddress = (PVOID)((ULONG_PTR)DeviceExtension->VirtualAddress + DeviceExtension->CommonBufferLength); if (VirtualAddress >= DeviceExtension->VirtualAddress && VirtualAddress < EndAddress) { Offset = (ULONG_PTR)VirtualAddress - (ULONG_PTR)DeviceExtension->VirtualAddress; @@ -506,14 +506,14 @@ } else { - EndAddress = Srb->DataBuffer + Srb->DataTransferLength; + EndAddress = (PVOID)((ULONG_PTR)Srb->DataBuffer + Srb->DataTransferLength); if (VirtualAddress == NULL) { VirtualAddress = Srb->DataBuffer; } else if (VirtualAddress < Srb->DataBuffer || VirtualAddress >= EndAddress) { - EndAddress = Srb->SenseInfoBuffer + Srb->SenseInfoBufferLength; + EndAddress = (PVOID)((ULONG_PTR)Srb->SenseInfoBuffer + Srb->SenseInfoBufferLength); if (VirtualAddress < Srb->SenseInfoBuffer || VirtualAddress >= EndAddress) { PhysicalAddress.QuadPart = 0LL; @@ -530,18 +530,18 @@ } BufferLength = PAGE_SIZE - (ULONG_PTR)VirtualAddress % PAGE_SIZE; - while (VirtualAddress + BufferLength < EndAddress) + while ((ULONG_PTR)VirtualAddress + BufferLength < (ULONG_PTR)EndAddress) { - NextPhysicalAddress = MmGetPhysicalAddress(VirtualAddress + BufferLength); + NextPhysicalAddress = MmGetPhysicalAddress((PVOID)((ULONG_PTR)VirtualAddress + BufferLength)); if (PhysicalAddress.QuadPart + BufferLength != NextPhysicalAddress.QuadPart) { break; } BufferLength += PAGE_SIZE; } - if (VirtualAddress + BufferLength >= EndAddress) + if ((ULONG_PTR)VirtualAddress + BufferLength >= (ULONG_PTR)EndAddress) { - BufferLength = EndAddress - VirtualAddress; + BufferLength = (ULONG)((ULONG_PTR)EndAddress - (ULONG_PTR)VirtualAddress); } } if (Length != NULL) @@ -1786,7 +1786,7 @@ if (index != 0xffffffff) { DeviceExtension->CurrentSrbExtensions++; - Srb->SrbExtension = DeviceExtension->VirtualAddress + index * DeviceExtension->SrbExtensionSize; + Srb->SrbExtension = (PVOID)((ULONG_PTR)DeviceExtension->VirtualAddress + index * DeviceExtension->SrbExtensionSize); } } DPRINT("%x\n", Srb->SrbExtension); _____ Modified: trunk/reactos/drivers/video/displays/vga/objects/bitblt.c --- trunk/reactos/drivers/video/displays/vga/objects/bitblt.c 2005-07-04 23:05:17 UTC (rev 16419) +++ trunk/reactos/drivers/video/displays/vga/objects/bitblt.c 2005-07-05 00:24:36 UTC (rev 16420) @@ -52,14 +52,14 @@ if (NULL == ColorTranslation || 0 != (ColorTranslation->flXlate & XO_TRIVIAL)) { DIB_BltToVGA(DestRect->left, DestRect->top, dx, dy, - Source->pvScan0 + SourcePoint->y * Source->lDelta + (SourcePoint->x >> 1), + (PVOID)((ULONG_PTR)Source->pvScan0 + SourcePoint->y * Source->lDelta + (SourcePoint->x >> 1)), Source->lDelta, SourcePoint->x % 2); } else { /* Perform color translation */ DIB_BltToVGAWithXlate(DestRect->left, DestRect->top, dx, dy, - Source->pvScan0 + SourcePoint->y * Source->lDelta + (SourcePoint->x >> 1), + (PVOID)((ULONG_PTR)Source->pvScan0 + SourcePoint->y * Source->lDelta + (SourcePoint->x >> 1)), Source->lDelta, ColorTranslation); } return FALSE; _____ Modified: trunk/reactos/drivers/video/displays/vga/vgavideo/vgavideo.c --- trunk/reactos/drivers/video/displays/vga/vgavideo/vgavideo.c 2005-07-04 23:05:17 UTC (rev 16419) +++ trunk/reactos/drivers/video/displays/vga/vgavideo/vgavideo.c 2005-07-05 00:24:36 UTC (rev 16420) @@ -409,7 +409,7 @@ /* Reset the destination. */ for (j = 0; j < h; j++) { - memset(b + (j * Dest_lDelta), 0, abs(Dest_lDelta)); + memset((PVOID)((ULONG_PTR)b + (j * Dest_lDelta)), 0, abs(Dest_lDelta)); } for (plane = 0; plane < 4; plane++) @@ -986,7 +986,7 @@ int i, j, dib_shift; bpX = b; - dib = bdib + y * dibw + (x / 2); + dib = (unsigned char *)bdib + y * dibw + (x / 2); for (i=w; i>0; i--) { @@ -1015,7 +1015,7 @@ int i, j, dib_shift, dib_and; bpX = b; - dib = bdib + y * dibw + (x / 2); + dib = (unsigned char *)bdib + y * dibw + (x / 2); for (i=w; i>0; i--) { _____ Modified: trunk/reactos/drivers/video/videoprt/videoprt.c --- trunk/reactos/drivers/video/videoprt/videoprt.c 2005-07-04 23:05:17 UTC (rev 16419) +++ trunk/reactos/drivers/video/videoprt/videoprt.c 2005-07-05 00:24:36 UTC (rev 16420) @@ -57,7 +57,7 @@ if (Va == 0) return NULL; - return (PVOID)(BaseAddress + Va); + return (PVOID)((ULONG_PTR)BaseAddress + Va); } PVOID STDCALL @@ -103,7 +103,7 @@ ((ULONG_PTR)BaseAddress + (ULONG_PTR)ExportDir->AddressOfNames); for (i = 0; i < ExportDir->NumberOfNames; i++, NamePtr++, OrdinalPtr++) { - if (!_strnicmp((PCHAR)FunctionName, (PCHAR)(BaseAddress + *NamePtr), + if (!_strnicmp((PCHAR)FunctionName, (PCHAR)((ULONG_PTR)BaseAddress + *NamePtr), strlen((PCHAR)FunctionName))) { return (PVOID)((ULONG_PTR)BaseAddress + _____ Modified: trunk/reactos/include/reactos/helper.h --- trunk/reactos/include/reactos/helper.h 2005-07-04 23:05:17 UTC (rev 16419) +++ trunk/reactos/include/reactos/helper.h 2005-07-05 00:24:36 UTC (rev 16420) @@ -25,7 +25,7 @@ sizeof (IMAGE_NT_SIGNATURE) + \ sizeof (IMAGE_FILE_HEADER))) #define TAG(A, B, C, D) (ULONG)(((A)<<0) + ((B)<<8) + ((C)<<16) + ((D)<<24)) -#define RVA(m, b) ((ULONG)b + m) +#define RVA(m, b) ((PVOID)((ULONG_PTR)(b) + (ULONG_PTR)(m))) #define NTSTAT_SEVERITY_SHIFT 30 #define NTSTAT_SEVERITY_MASK 0x00000003 #define NTSTAT_FACILITY_SHIFT 16 _____ Modified: trunk/reactos/lib/crt/search/lsearch.c --- trunk/reactos/lib/crt/search/lsearch.c 2005-07-04 23:05:17 UTC (rev 16419) +++ trunk/reactos/lib/crt/search/lsearch.c 2005-07-05 00:24:36 UTC (rev 16420) @@ -13,11 +13,8 @@ if (ret_find != NULL) return ret_find; -#ifdef __GNUC__ - memcpy(base + (*nelp*width), key, width); -#else - memcpy((int*)base + (*nelp*width), key, width); -#endif + memcpy((void*)((int*)base + (*nelp*width)), key, width); + (*nelp)++; return base; } _____ Modified: trunk/reactos/lib/kernel32/file/find.c --- trunk/reactos/lib/kernel32/file/find.c 2005-07-04 23:05:17 UTC (rev 16419) +++ trunk/reactos/lib/kernel32/file/find.c 2005-07-05 00:24:36 UTC (rev 16420) @@ -54,11 +54,11 @@ if (IData->pFileInfo->NextEntryOffset != 0) { - IData->pFileInfo = (PVOID)IData->pFileInfo + IData->pFileInfo->NextEntryOffset; + IData->pFileInfo = (PVOID)((ULONG_PTR)IData->pFileInfo + IData->pFileInfo->NextEntryOffset); DPRINT("Found %.*S\n",IData->pFileInfo->FileNameLength/sizeof(WCHAR), IData->pFileInfo->FileName); return TRUE; } - IData->pFileInfo = (PVOID)IData + sizeof(KERNEL32_FIND_FILE_DATA); + IData->pFileInfo = (PVOID)((ULONG_PTR)IData + sizeof(KERNEL32_FIND_FILE_DATA)); IData->pFileInfo->FileIndex = 0; Status = NtQueryDirectoryFile (IData->DirectoryHandle, NULL, @@ -271,7 +271,7 @@ SetLastErrorByStatus (Status); return(NULL); } - IData->pFileInfo = (PVOID)IData + sizeof(KERNEL32_FIND_FILE_DATA); + IData->pFileInfo = (PVOID)((ULONG_PTR)IData + sizeof(KERNEL32_FIND_FILE_DATA)); IData->pFileInfo->FileIndex = 0; Status = NtQueryDirectoryFile (IData->DirectoryHandle, _____ Modified: trunk/reactos/lib/kernel32/mem/global.c --- trunk/reactos/lib/kernel32/mem/global.c 2005-07-04 23:05:17 UTC (rev 16419) +++ trunk/reactos/lib/kernel32/mem/global.c 2005-07-05 00:24:36 UTC (rev 16420) @@ -39,7 +39,7 @@ #define HANDLE_TO_INTERN(h) ((PGLOBAL_HANDLE)(((char *)(h))-4)) #define INTERN_TO_HANDLE(i) ((HGLOBAL) &((i)->Pointer)) -#define POINTER_TO_HANDLE(p) (*(PHANDLE)(p - HANDLE_SIZE)) +#define POINTER_TO_HANDLE(p) (*(PHANDLE)((ULONG_PTR)p - HANDLE_SIZE)) #define ISHANDLE(h) ((((ULONG)(h)) & 0x4)!=0) #define ISPOINTER(h) ((((ULONG)(h)) & 0x4)==0) @@ -105,7 +105,7 @@ if (palloc) { *(PHANDLE)palloc = INTERN_TO_HANDLE(phandle); - phandle->Pointer = palloc + HANDLE_SIZE; + phandle->Pointer = (PVOID)((ULONG_PTR)palloc + HANDLE_SIZE); } else /*failed to allocate the memory block*/ { @@ -237,7 +237,7 @@ } if(phandle->Pointer) - RtlFreeHeap(GetProcessHeap(), 0, phandle->Pointer - HANDLE_SIZE); + RtlFreeHeap(GetProcessHeap(), 0, (PVOID)((ULONG_PTR)phandle->Pointer - HANDLE_SIZE)); RtlFreeHeap(GetProcessHeap(), 0, phandle); } @@ -549,7 +549,7 @@ if(phandle->Pointer) { palloc = RtlReAllocateHeap(GetProcessHeap(), heap_flags, - phandle->Pointer - HANDLE_SIZE, + (PVOID)((ULONG_PTR)phandle->Pointer - HANDLE_SIZE), dwBytes + HANDLE_SIZE); if (0 == palloc) { @@ -558,7 +558,7 @@ else { *(PHANDLE)palloc = hMem; - phandle->Pointer = palloc + HANDLE_SIZE; + phandle->Pointer = (PVOID)((ULONG_PTR)palloc + HANDLE_SIZE); } } else @@ -571,7 +571,7 @@ else { *(PHANDLE)palloc = hMem; - phandle->Pointer = palloc + HANDLE_SIZE; + phandle->Pointer = (PVOID)((ULONG_PTR)palloc + HANDLE_SIZE); } } } @@ -579,7 +579,7 @@ { if(phandle->Pointer) { - RtlFreeHeap(GetProcessHeap(), 0, phandle->Pointer - HANDLE_SIZE); + RtlFreeHeap(GetProcessHeap(), 0, (PVOID)((ULONG_PTR)phandle->Pointer - HANDLE_SIZE)); phandle->Pointer = 0; } } @@ -613,7 +613,7 @@ { if (0 != phandle->Pointer)/*NOT DISCARDED*/ { - retval = RtlSizeHeap(GetProcessHeap(), 0, phandle->Pointer - HANDLE_SIZE); + retval = RtlSizeHeap(GetProcessHeap(), 0, (PVOID)((ULONG_PTR)phandle->Pointer - HANDLE_SIZE)); if (retval == (SIZE_T)-1) /*RtlSizeHeap failed*/ { _____ Modified: trunk/reactos/lib/kernel32/process/create.c --- trunk/reactos/lib/kernel32/process/create.c 2005-07-04 23:05:17 UTC (rev 16419) +++ trunk/reactos/lib/kernel32/process/create.c 2005-07-05 00:24:36 UTC (rev 16420) @@ -505,7 +505,7 @@ while(*ptr++); } ptr++; - EnvSize = (PVOID)ptr - ParentEnv; + EnvSize = (ULONG)((ULONG_PTR)ptr - (ULONG_PTR)ParentEnv); } else if (NtCurrentPeb()->ProcessParameters->Environment != NULL) { @@ -572,7 +572,7 @@ /* write pointer to environment */ Offset = FIELD_OFFSET(RTL_USER_PROCESS_PARAMETERS, Environment); NtWriteVirtualMemory(ProcessHandle, - (PVOID)(PpbBase + Offset), + (PVOID)((ULONG_PTR)PpbBase + Offset), &EnvPtr, sizeof(EnvPtr), &BytesWritten); _____ Modified: trunk/reactos/lib/ntdll/csr/lpc.c --- trunk/reactos/lib/ntdll/csr/lpc.c 2005-07-04 23:05:17 UTC (rev 16419) +++ trunk/reactos/lib/ntdll/csr/lpc.c 2005-07-05 00:24:36 UTC (rev 16420) @@ -48,7 +48,7 @@ memcpy(Block, ParameterBuffer, ParameterBufferSize); } *ClientAddress = Block; - *ServerAddress = Block - CsrSectionMapBase + CsrSectionMapServerBase; + *ServerAddress = (PVOID)((ULONG_PTR)Block - (ULONG_PTR)CsrSectionMapBase + (ULONG_PTR)CsrSectionMapServerBase); return(STATUS_SUCCESS); } _____ Modified: trunk/reactos/lib/ntdll/ldr/startup.c --- trunk/reactos/lib/ntdll/ldr/startup.c 2005-07-04 23:05:17 UTC (rev 16419) +++ trunk/reactos/lib/ntdll/ldr/startup.c 2005-07-05 00:24:36 UTC (rev 16420) @@ -266,7 +266,7 @@ &NlsTable); RtlResetRtlTranslations (&NlsTable); - NTHeaders = (PIMAGE_NT_HEADERS)(ImageBase + PEDosHeader->e_lfanew); + NTHeaders = (PIMAGE_NT_HEADERS)((ULONG_PTR)ImageBase + PEDosHeader->e_lfanew); /* Get number of processors */ Status = ZwQuerySystemInformation(SystemBasicInformation, _____ Modified: trunk/reactos/lib/ntdll/ldr/utils.c --- trunk/reactos/lib/ntdll/ldr/utils.c 2005-07-04 23:05:17 UTC (rev 16419) +++ trunk/reactos/lib/ntdll/ldr/utils.c 2005-07-05 00:24:36 UTC (rev 16420) @@ -162,7 +162,7 @@ TRACE_LDR("%wZ - Calling tls callback at %x\n", &Module->BaseDllName, TlsCallback); TlsCallback(Module->DllBase, dwReason, NULL); - TlsCallback++; + TlsCallback = (PIMAGE_TLS_CALLBACK)((ULONG_PTR)TlsCallback + sizeof(PVOID)); } } } @@ -205,7 +205,7 @@ return STATUS_NO_MEMORY; } - TlsData = (PVOID)TlsPointers + LdrpTlsCount * sizeof(PVOID); + TlsData = (PVOID)((ULONG_PTR)TlsPointers + LdrpTlsCount * sizeof(PVOID)); Teb->ThreadLocalStoragePointer = TlsPointers; TlsInfo = LdrpTlsArray; @@ -216,12 +216,12 @@ if (TlsInfo->TlsDataSize) { memcpy(TlsData, TlsInfo->StartAddressOfRawData, TlsInfo->TlsDataSize); - TlsData += TlsInfo->TlsDataSize; + TlsData = (PVOID)((ULONG_PTR)TlsData + TlsInfo->TlsDataSize); } if (TlsInfo->TlsZeroSize) { memset(TlsData, 0, TlsInfo->TlsZeroSize); - TlsData += TlsInfo->TlsZeroSize; + TlsData = (PVOID)((ULONG_PTR)TlsData + TlsInfo->TlsZeroSize); } } } @@ -471,7 +471,7 @@ Module->DllBase = (PVOID)ImageBase; Module->EntryPoint = (PVOID)NTHeaders->OptionalHeader.AddressOfEntryPoint; if (Module->EntryPoint != 0) - Module->EntryPoint += (ULONG)Module->DllBase; + Module->EntryPoint = (PVOID)((ULONG_PTR)Module->EntryPoint + (ULONG_PTR)Module->DllBase); Module->SizeOfImage = LdrpGetResidentSize(NTHeaders); if (NtCurrentPeb()->Ldr->Initialized == TRUE) { @@ -803,7 +803,7 @@ DPRINT("Scanning %wZ at %p\n", &ModulePtr->BaseDllName, ModulePtr->DllBase); if ((Address >= ModulePtr->DllBase) && - (Address <= (ModulePtr->DllBase + ModulePtr->SizeOfImage))) + ((ULONG_PTR)Address <= ((ULONG_PTR)ModulePtr->DllBase + ModulePtr->SizeOfImage))) { *Module = ModulePtr; RtlLeaveCriticalSection(NtCurrentPeb()->LoaderLock); @@ -1030,7 +1030,7 @@ ExportDir->AddressOfFunctions ); DPRINT( - "LdrGetExportByOrdinal(Ordinal %d) = %x\n", + "LdrGetExportByOrdinal(Ordinal %d) = %p\n", Ordinal, RVA(BaseAddress, ExFunctions[Ordinal - ExportDir->Base] ) ); @@ -1270,7 +1270,7 @@ { Count = (RelocationDir->SizeOfBlock - sizeof(IMAGE_BASE_RELOCATION)) / sizeof(USHORT); - Page = ImageBase + RelocationDir->VirtualAddress; + Page = (PVOID)((ULONG_PTR)ImageBase + (ULONG_PTR)RelocationDir->VirtualAddress); TypeOffset = (PUSHORT)(RelocationDir + 1); /* Unprotect the page(s) we're about to relocate. */ @@ -1289,7 +1289,7 @@ if (RelocationDir->VirtualAddress + PAGE_SIZE < NTHeaders->OptionalHeader.SizeOfImage) { - ProtectPage2 = ProtectPage + PAGE_SIZE; + ProtectPage2 = (PVOID)((ULONG_PTR)ProtectPage + PAGE_SIZE); Status = NtProtectVirtualMemory(NtCurrentProcess(), &ProtectPage2, &ProtectSize, @@ -1391,16 +1391,16 @@ } /* Get the import address list. */ - ImportAddressList = (PVOID *)(Module->DllBase + (ULONG_PTR)ImportModuleDirectory->FirstThunk); + ImportAddressList = (PVOID *)((ULONG_PTR)Module->DllBase + (ULONG_PTR)ImportModuleDirectory->FirstThunk); /* Get the list of functions to import. */ if (ImportModuleDirectory->OriginalFirstThunk != 0) { - FunctionNameList = (PULONG) (Module->DllBase + (ULONG_PTR)ImportModuleDirectory->OriginalFirstThunk); + FunctionNameList = (PULONG) ((ULONG_PTR)Module->DllBase + (ULONG_PTR)ImportModuleDirectory->OriginalFirstThunk); } else { - FunctionNameList = (PULONG)(Module->DllBase + (ULONG_PTR)ImportModuleDirectory->FirstThunk); + FunctionNameList = (PULONG)((ULONG_PTR)Module->DllBase + (ULONG_PTR)ImportModuleDirectory->FirstThunk); } /* Get the size of IAT. */ @@ -1550,16 +1550,16 @@ { /* Get the import address list. */ - ImportAddressList = (PVOID *)(Module->DllBase + (ULONG_PTR)ImportModuleDirectory->FirstThunk); + ImportAddressList = (PVOID *)((ULONG_PTR)Module->DllBase + (ULONG_PTR)ImportModuleDirectory->FirstThunk); /* Get the list of functions to import. */ if (ImportModuleDirectory->OriginalFirstThunk != 0) { - FunctionNameList = (PULONG) (Module->DllBase + (ULONG_PTR)ImportModuleDirectory->OriginalFirstThunk); + FunctionNameList = (PULONG) ((ULONG_PTR)Module->DllBase + (ULONG_PTR)ImportModuleDirectory->OriginalFirstThunk); } else { - FunctionNameList = (PULONG)(Module->DllBase + (ULONG_PTR)ImportModuleDirectory->FirstThunk); + FunctionNameList = (PULONG)((ULONG_PTR)Module->DllBase + (ULONG_PTR)ImportModuleDirectory->FirstThunk); } /* Get the size of IAT. */ @@ -1585,15 +1585,15 @@ NTHeaders = RtlImageNtHeader (ImportedModule->DllBase); Start = (PVOID)NTHeaders->OptionalHeader.ImageBase; - End = Start + ImportedModule->SizeOfImage; - Offset = ImportedModule->DllBase - Start; + End = (PVOID)((ULONG_PTR)Start + ImportedModule->SizeOfImage); + Offset = (ULONG)((ULONG_PTR)ImportedModule->DllBase - (ULONG_PTR)Start); /* Walk through function list and fixup addresses. */ while (*FunctionNameList != 0L) { if (*ImportAddressList >= Start && *ImportAddressList < End) { - (*ImportAddressList) += Offset; + (*ImportAddressList) = (PVOID)((ULONG_PTR)(*ImportAddressList) + Offset); } ImportAddressList++; FunctionNameList++; @@ -1903,7 +1903,7 @@ * to the DLL's image. */ DosHeader = (PIMAGE_DOS_HEADER) ImageBase; - NTHeaders = (PIMAGE_NT_HEADERS) (ImageBase + DosHeader->e_lfanew); + NTHeaders = (PIMAGE_NT_HEADERS) ((ULONG_PTR)ImageBase + DosHeader->e_lfanew); /* * If the base address is different from the @@ -1978,7 +1978,7 @@ DPRINT("AddressOfEntryPoint = %x\n",(ULONG)NTHeaders->OptionalHeader.AddressOfEntryPoint); if (NTHeaders->OptionalHeader.AddressOfEntryPoint != 0) { - EntryPoint = (PEPFUNC) (ImageBase + EntryPoint = (PEPFUNC) ((ULONG_PTR)ImageBase + NTHeaders->OptionalHeader.AddressOfEntryPoint); } DPRINT("LdrPEStartup() = %x\n",EntryPoint); @@ -3108,17 +3108,17 @@ break; case IMAGE_REL_BASED_HIGH: - ShortPtr = (PUSHORT)(Address + Offset); + ShortPtr = (PUSHORT)((ULONG_PTR)Address + Offset); *ShortPtr += HIWORD(Delta); break; case IMAGE_REL_BASED_LOW: - ShortPtr = (PUSHORT)(Address + Offset); + ShortPtr = (PUSHORT)((ULONG_PTR)Address + Offset); *ShortPtr += LOWORD(Delta); break; case IMAGE_REL_BASED_HIGHLOW: - LongPtr = (PULONG)(Address + Offset); + LongPtr = (PULONG)((ULONG_PTR)Address + Offset); *LongPtr += Delta; break; _____ Modified: trunk/reactos/lib/rosrtl/thread/i386/context.c --- trunk/reactos/lib/rosrtl/thread/i386/context.c 2005-07-04 23:05:17 UTC (rev 16419) +++ trunk/reactos/lib/rosrtl/thread/i386/context.c 2005-07-05 00:24:36 UTC (rev 16420) @@ -44,7 +44,7 @@ if(!NT_SUCCESS(nErrCode)) return nErrCode; /* too many parameters */ - if((nParamsSize + sizeof(ULONG_PTR)) > (SIZE_T)(pStackBase - pStackLimit)) + if((nParamsSize + sizeof(ULONG_PTR)) > (SIZE_T)((ULONG_PTR)pStackBase - (ULONG_PTR)pStackLimit)) return STATUS_STACK_OVERFLOW; memset(Context, 0, sizeof(CONTEXT)); _____ Modified: trunk/reactos/lib/rtl/image.c --- trunk/reactos/lib/rtl/image.c 2005-07-04 23:05:17 UTC (rev 16419) +++ trunk/reactos/lib/rtl/image.c 2005-07-05 00:24:36 UTC (rev 16420) @@ -72,7 +72,7 @@ *Size = NtHeader->OptionalHeader.DataDirectory[Directory].Size; if (bFlag) - return (PVOID)(BaseAddress + Va); + return (PVOID)((ULONG_PTR)BaseAddress + Va); /* image mapped as ordinary file, we must find raw pointer */ return (PVOID)RtlImageRvaToVa (NtHeader, BaseAddress, Va, NULL); @@ -138,10 +138,10 @@ *SectionHeader = Section; } - return (ULONG)(BaseAddress + + return (ULONG)((ULONG_PTR)BaseAddress + Rva + Section->PointerToRawData - - Section->VirtualAddress); + (ULONG_PTR)Section->VirtualAddress); } /* EOF */ _____ Modified: trunk/reactos/lib/rtl/process.c --- trunk/reactos/lib/rtl/process.c 2005-07-04 23:05:17 UTC (rev 16419) +++ trunk/reactos/lib/rtl/process.c 2005-07-05 00:24:36 UTC (rev 16420) @@ -161,7 +161,7 @@ /* write pointer to environment */ Offset = FIELD_OFFSET(RTL_USER_PROCESS_PARAMETERS, Environment); ZwWriteVirtualMemory(ProcessHandle, - (PVOID)(PpbBase + Offset), + (PVOID)((ULONG_PTR)PpbBase + Offset), &EnvPtr, sizeof(EnvPtr), &BytesWritten); @@ -291,7 +291,7 @@ 0, &Sii.StackReserve, &Sii.StackCommit, - ImageBaseAddress + (ULONG)Sii.EntryPoint, + (PVOID)((ULONG_PTR)ImageBaseAddress + (ULONG_PTR)Sii.EntryPoint), (PVOID)PEB_BASE, &ProcessInfo->ThreadHandle, &ProcessInfo->ClientId _____ Modified: trunk/reactos/lib/rtl/registry.c --- trunk/reactos/lib/rtl/registry.c 2005-07-04 23:05:17 UTC (rev 16419) +++ trunk/reactos/lib/rtl/registry.c 2005-07-05 00:24:36 UTC (rev 16420) @@ -787,7 +787,7 @@ !(QueryEntry->Flags & RTL_QUERY_REGISTRY_NOEXPAND)) { DPRINT("Expand REG_MULTI_SZ type\n"); - StringPtr = (PWSTR)((PVOID)FullValueInfo + FullValueInfo->DataOffset); + StringPtr = (PWSTR)((ULONG_PTR)FullValueInfo + FullValueInfo->DataOffset); while (*StringPtr != 0) { StringLen = (wcslen(StringPtr) + 1) * sizeof(WCHAR); @@ -807,7 +807,7 @@ { DPRINT("Expand REG_EXPAND_SZ type\n"); - StringPtr = (PWSTR)((PVOID)FullValueInfo + FullValueInfo->DataOffset); + StringPtr = (PWSTR)((ULONG_PTR)FullValueInfo + FullValueInfo->DataOffset); ExpandBuffer = ExAllocatePool(PagedPool, FullValueInfo->DataLength * 2); if (ExpandBuffer == NULL) { @@ -841,7 +841,7 @@ { Status = QueryEntry->QueryRoutine(ValueName, FullValueInfo->Type, - (PVOID)FullValueInfo + FullValueInfo->DataOffset, + (PVOID)((ULONG_PTR)FullValueInfo + FullValueInfo->DataOffset), FullValueInfo->DataLength, Context, QueryEntry->EntryContext); _____ Modified: trunk/reactos/lib/user32/windows/bitmap.c --- trunk/reactos/lib/user32/windows/bitmap.c 2005-07-04 23:05:17 UTC (rev 16419) +++ trunk/reactos/lib/user32/windows/bitmap.c 2005-07-05 00:24:36 UTC (rev 16420) @@ -534,7 +534,7 @@ } HeaderSize = sizeof(BITMAPINFOHEADER) + ColorCount * sizeof(RGBQUAD); } - Data = (PVOID)BitmapInfo + HeaderSize; + Data = (PVOID)((ULONG_PTR)BitmapInfo + HeaderSize); PrivateInfo = RtlAllocateHeap(GetProcessHeap(), 0, HeaderSize); if (PrivateInfo == NULL)
19 years, 6 months
1
0
0
0
[weiden] 16419: fix code that depends on GCC's void* pointer arithmetic extension
by weiden@svn.reactos.com
fix code that depends on GCC's void* pointer arithmetic extension Modified: trunk/reactos/boot/freeldr/freeldr/arch/i386/hardware.c Modified: trunk/reactos/boot/freeldr/freeldr/arch/i386/hwpci.c Modified: trunk/reactos/boot/freeldr/freeldr/arch/i386/pcdisk.c Modified: trunk/reactos/boot/freeldr/freeldr/arch/i386/xboxdisk.c Modified: trunk/reactos/boot/freeldr/freeldr/cache/cache.c Modified: trunk/reactos/boot/freeldr/freeldr/fs/ext2.c Modified: trunk/reactos/boot/freeldr/freeldr/fs/fat.c Modified: trunk/reactos/boot/freeldr/freeldr/fs/iso.c Modified: trunk/reactos/boot/freeldr/freeldr/linuxboot.c Modified: trunk/reactos/boot/freeldr/freeldr/mm/meminit.c Modified: trunk/reactos/boot/freeldr/freeldr/mm/mm.c Modified: trunk/reactos/boot/freeldr/freeldr/multiboot.c _____ Modified: trunk/reactos/boot/freeldr/freeldr/arch/i386/hardware.c --- trunk/reactos/boot/freeldr/freeldr/arch/i386/hardware.c 2005-07-04 22:25:46 UTC (rev 16418) +++ trunk/reactos/boot/freeldr/freeldr/arch/i386/hardware.c 2005-07-04 23:05:17 UTC (rev 16419) @@ -363,7 +363,7 @@ FullResourceDescriptor->PartialResourceList.PartialDescriptors[0].ShareD isposition = CmResourceShareUndetermined; - Ptr = (char *)(((PVOID)&FullResourceDescriptor->PartialResourceList.PartialDescripto rs[0]) + + Ptr = (char *)(((ULONG_PTR)&FullResourceDescriptor->PartialResourceList.PartialDescr iptors[0]) + sizeof(CM_PARTIAL_RESOURCE_DESCRIPTOR)); /* Set instalation check data */ @@ -460,7 +460,7 @@ sizeof(CM_DISK_GEOMETRY_DEVICE_DATA); /* Get pointer to geometry data */ - DiskGeometry = ((PVOID)FullResourceDescriptor) + sizeof(CM_FULL_RESOURCE_DESCRIPTOR); + DiskGeometry = (PVOID)(((ULONG_PTR)FullResourceDescriptor) + sizeof(CM_FULL_RESOURCE_DESCRIPTOR)); /* Get the disk geometry */ ExtGeometry.Size = sizeof(EXTENDED_GEOMETRY); @@ -648,7 +648,7 @@ sizeof(CM_INT13_DRIVE_PARAMETER) * DiskCount; /* Get harddisk Int13 geometry data */ - Int13Drives = ((PVOID)FullResourceDescriptor) + sizeof(CM_FULL_RESOURCE_DESCRIPTOR); + Int13Drives = (PVOID)(((ULONG_PTR)FullResourceDescriptor) + sizeof(CM_FULL_RESOURCE_DESCRIPTOR)); for (i = 0; i < DiskCount; i++) { if (MachDiskGetDriveGeometry(0x80 + i, &Geometry)) @@ -744,7 +744,7 @@ PUSHORT SegPtr = (PUSHORT)0x7A; PUSHORT OfsPtr = (PUSHORT)0x78; - return (PVOID)(((ULONG)(*SegPtr)) << 4) + (ULONG)(*OfsPtr); + return (PVOID)((ULONG_PTR)(((ULONG)(*SegPtr)) << 4) + (ULONG)(*OfsPtr)); } @@ -814,7 +814,7 @@ PartialDescriptor->ShareDisposition = CmResourceShareUndetermined; PartialDescriptor->u.DeviceSpecificData.DataSize = sizeof(CM_FLOPPY_DEVICE_DATA); - FloppyData = ((PVOID)FullResourceDescriptor) + sizeof(CM_FULL_RESOURCE_DESCRIPTOR); + FloppyData = (PVOID)(((ULONG_PTR)FullResourceDescriptor) + sizeof(CM_FULL_RESOURCE_DESCRIPTOR)); FloppyData->Version = 2; FloppyData->Revision = 0; FloppyData->MaxDensity = MaxDensity[FloppyType]; @@ -1691,7 +1691,7 @@ PartialDescriptor->ShareDisposition = CmResourceShareUndetermined; PartialDescriptor->u.DeviceSpecificData.DataSize = sizeof(CM_KEYBOARD_DEVICE_DATA); - KeyboardData = ((PVOID)FullResourceDescriptor) + sizeof(CM_FULL_RESOURCE_DESCRIPTOR); + KeyboardData = (PVOID)(((ULONG_PTR)FullResourceDescriptor) + sizeof(CM_FULL_RESOURCE_DESCRIPTOR)); KeyboardData->Version = 0; KeyboardData->Revision = 0; KeyboardData->Type = 4; _____ Modified: trunk/reactos/boot/freeldr/freeldr/arch/i386/hwpci.c --- trunk/reactos/boot/freeldr/freeldr/arch/i386/hwpci.c 2005-07-04 22:25:46 UTC (rev 16418) +++ trunk/reactos/boot/freeldr/freeldr/arch/i386/hwpci.c 2005-07-04 23:05:17 UTC (rev 16419) @@ -208,7 +208,7 @@ PartialDescriptor->ShareDisposition = CmResourceShareUndetermined; PartialDescriptor->u.DeviceSpecificData.DataSize = Table->Size; - memcpy(((PVOID)FullResourceDescriptor) + sizeof(CM_FULL_RESOURCE_DESCRIPTOR), + memcpy((PVOID)((ULONG_PTR)FullResourceDescriptor + sizeof(CM_FULL_RESOURCE_DESCRIPTOR)), Table, Table->Size); _____ Modified: trunk/reactos/boot/freeldr/freeldr/arch/i386/pcdisk.c --- trunk/reactos/boot/freeldr/freeldr/arch/i386/pcdisk.c 2005-07-04 22:25:46 UTC (rev 16418) +++ trunk/reactos/boot/freeldr/freeldr/arch/i386/pcdisk.c 2005-07-04 23:05:17 UTC (rev 16419) @@ -258,7 +258,7 @@ // of checking the sector read count we will rely solely // on the carry flag being set on error - Buffer += (NumberOfSectorsToRead * DriveGeometry.BytesPerSector); + Buffer = (PVOID)((ULONG_PTR)Buffer + (NumberOfSectorsToRead * DriveGeometry.BytesPerSector)); SectorCount -= NumberOfSectorsToRead; SectorNumber += NumberOfSectorsToRead; } _____ Modified: trunk/reactos/boot/freeldr/freeldr/arch/i386/xboxdisk.c --- trunk/reactos/boot/freeldr/freeldr/arch/i386/xboxdisk.c 2005-07-04 22:25:46 UTC (rev 16418) +++ trunk/reactos/boot/freeldr/freeldr/arch/i386/xboxdisk.c 2005-07-04 23:05:17 UTC (rev 16419) @@ -387,7 +387,7 @@ if (Junk == FALSE) { IDEReadBlock(CommandPort, Buffer, IDE_SECTOR_BUF_SZ); - Buffer += IDE_SECTOR_BUF_SZ; + Buffer = (PVOID)((ULONG_PTR)Buffer + IDE_SECTOR_BUF_SZ); } else { _____ Modified: trunk/reactos/boot/freeldr/freeldr/cache/cache.c --- trunk/reactos/boot/freeldr/freeldr/cache/cache.c 2005-07-04 22:25:46 UTC (rev 16418) +++ trunk/reactos/boot/freeldr/freeldr/cache/cache.c 2005-07-04 23:05:17 UTC (rev 16419) @@ -164,14 +164,14 @@ // Copy the portion requested into the buffer // RtlCopyMemory(Buffer, - (CacheBlock->BlockData + (SectorOffsetInStartBlock * CacheManagerDrive.BytesPerSector)), + (PVOID)((ULONG_PTR)CacheBlock->BlockData + (SectorOffsetInStartBlock * CacheManagerDrive.BytesPerSector)), (CopyLengthInStartBlock * CacheManagerDrive.BytesPerSector)); DbgPrint((DPRINT_CACHE, "1 - RtlCopyMemory(0x%x, 0x%x, %d)\n", Buffer, (CacheBlock->BlockData + (SectorOffsetInStartBlock * CacheManagerDrive.BytesPerSector)), (CopyLengthInStartBlock * CacheManagerDrive.BytesPerSector))); // // Update the buffer address // - Buffer += (CopyLengthInStartBlock * CacheManagerDrive.BytesPerSector); + Buffer = (PVOID)((ULONG_PTR)Buffer + (CopyLengthInStartBlock * CacheManagerDrive.BytesPerSector)); // // Update the block count @@ -204,7 +204,7 @@ // // Update the buffer address // - Buffer += CacheManagerDrive.BlockSize * CacheManagerDrive.BytesPerSector; + Buffer = (PVOID)((ULONG_PTR)Buffer + (CacheManagerDrive.BlockSize * CacheManagerDrive.BytesPerSector)); // // Update the block count @@ -237,7 +237,7 @@ // // Update the buffer address // - Buffer += SectorOffsetInEndBlock * CacheManagerDrive.BytesPerSector; + Buffer = (PVOID)((ULONG_PTR)Buffer + (SectorOffsetInEndBlock * CacheManagerDrive.BytesPerSector)); // // Update the block count _____ Modified: trunk/reactos/boot/freeldr/freeldr/fs/ext2.c --- trunk/reactos/boot/freeldr/freeldr/fs/ext2.c 2005-07-04 22:25:46 UTC (rev 16418) +++ trunk/reactos/boot/freeldr/freeldr/fs/ext2.c 2005-07-04 23:05:17 UTC (rev 16419) @@ -298,7 +298,7 @@ for (CurrentOffset=0; CurrentOffset<DirectorySize; ) { - CurrentDirectoryEntry = (PEXT2_DIR_ENTRY)(DirectoryBuffer + CurrentOffset); + CurrentDirectoryEntry = (PEXT2_DIR_ENTRY)((ULONG_PTR)DirectoryBuffer + CurrentOffset); if (CurrentDirectoryEntry->rec_len == 0) { @@ -401,7 +401,7 @@ DbgPrint((DPRINT_FILESYSTEM, "Reading fast symbolic link data\n")); // Copy the data from the link - RtlCopyMemory(Buffer, (PVOID)(Ext2FileInfo->Inode.i_block) + Ext2FileInfo->FilePointer, BytesToRead); + RtlCopyMemory(Buffer, (PVOID)((ULONG_PTR)Ext2FileInfo->FilePointer + Ext2FileInfo->Inode.i_block), BytesToRead); if (BytesRead != NULL) { @@ -466,7 +466,7 @@ } BytesToRead -= LengthInBlock; Ext2FileInfo->FilePointer += LengthInBlock; - Buffer += LengthInBlock; + Buffer = (PVOID)((ULONG_PTR)Buffer + LengthInBlock); } // @@ -497,7 +497,7 @@ } BytesToRead -= Ext2BlockSizeInBytes; Ext2FileInfo->FilePointer += Ext2BlockSizeInBytes; - Buffer += Ext2BlockSizeInBytes; + Buffer = (PVOID)((ULONG_PTR)Buffer + Ext2BlockSizeInBytes); NumberOfBlocks--; } } @@ -523,7 +523,7 @@ } Ext2FileInfo->FilePointer += BytesToRead; BytesToRead -= BytesToRead; - Buffer += BytesToRead; + Buffer = (PVOID)((ULONG_PTR)Buffer + (ULONG_PTR)BytesToRead); } return TRUE; @@ -878,7 +878,7 @@ return FALSE; } - memcpy(Buffer, ((PVOID)FILESYSBUFFER + StartingOffset), Length); + memcpy(Buffer, (PVOID)((ULONG_PTR)FILESYSBUFFER + StartingOffset), Length); return TRUE; } _____ Modified: trunk/reactos/boot/freeldr/freeldr/fs/fat.c --- trunk/reactos/boot/freeldr/freeldr/fs/fat.c 2005-07-04 22:25:46 UTC (rev 16418) +++ trunk/reactos/boot/freeldr/freeldr/fs/fat.c 2005-07-04 23:05:17 UTC (rev 16419) @@ -860,7 +860,7 @@ } } - fat = *((USHORT *) ((PVOID)FILESYSBUFFER + ThisFatEntOffset)); + fat = *((USHORT *) ((ULONG_PTR)FILESYSBUFFER + ThisFatEntOffset)); if (Cluster & 0x0001) fat = fat >> 4; /* Cluster number is ODD */ else @@ -880,7 +880,7 @@ return FALSE; } - fat = *((USHORT *) ((PVOID)FILESYSBUFFER + ThisFatEntOffset)); + fat = *((USHORT *) ((ULONG_PTR)FILESYSBUFFER + ThisFatEntOffset)); break; @@ -897,7 +897,7 @@ } // Get the fat entry - fat = (*((ULONG *) ((PVOID)FILESYSBUFFER + ThisFatEntOffset))) & 0x0FFFFFFF; + fat = (*((ULONG *) ((ULONG_PTR)FILESYSBUFFER + ThisFatEntOffset))) & 0x0FFFFFFF; break; @@ -1091,7 +1091,7 @@ // // Increment buffer address by cluster size // - Buffer += SectorsPerCluster * BytesPerSector; + Buffer = (PVOID)((ULONG_PTR)Buffer + (SectorsPerCluster * BytesPerSector)); // // Get next cluster @@ -1132,7 +1132,7 @@ return FALSE; } - memcpy(Buffer, ((PVOID)FILESYSBUFFER + StartingOffset), Length); + memcpy(Buffer, (PVOID)((ULONG_PTR)FILESYSBUFFER + StartingOffset), Length); return TRUE; } @@ -1234,7 +1234,7 @@ } BytesToRead -= LengthInCluster; FatFileInfo->FilePointer += LengthInCluster; - Buffer += LengthInCluster; + Buffer = (PVOID)((ULONG_PTR)Buffer + LengthInCluster); } // @@ -1265,7 +1265,7 @@ } BytesToRead -= (NumberOfClusters * BytesPerCluster); FatFileInfo->FilePointer += (NumberOfClusters * BytesPerCluster); - Buffer += (NumberOfClusters * BytesPerCluster); + Buffer = (PVOID)((ULONG_PTR)Buffer + (NumberOfClusters * BytesPerCluster)); } } @@ -1290,7 +1290,7 @@ } FatFileInfo->FilePointer += BytesToRead; BytesToRead -= BytesToRead; - Buffer += BytesToRead; + Buffer = (PVOID)((ULONG_PTR)Buffer + BytesToRead); } return TRUE; _____ Modified: trunk/reactos/boot/freeldr/freeldr/fs/iso.c --- trunk/reactos/boot/freeldr/freeldr/fs/iso.c 2005-07-04 22:25:46 UTC (rev 16418) +++ trunk/reactos/boot/freeldr/freeldr/fs/iso.c 2005-07-04 23:05:17 UTC (rev 16419) @@ -81,12 +81,12 @@ while (TRUE) { Offset = Offset + Record->RecordLength; - Record = (PDIR_RECORD)(DirectoryBuffer + Offset); + Record = (PDIR_RECORD)((ULONG_PTR)DirectoryBuffer + Offset); if (Record->RecordLength == 0) { Offset = ROUND_UP(Offset, SECTORSIZE); - Record = (PDIR_RECORD)(DirectoryBuffer + Offset); + Record = (PDIR_RECORD)((ULONG_PTR)DirectoryBuffer + Offset); } if (Offset >= DirectoryLength) @@ -159,7 +159,7 @@ // // Now read directory contents into DirectoryBuffer // - for (i = 0, Ptr = DirectoryBuffer; i < SectorCount; i++, Ptr += SECTORSIZE) + for (i = 0, Ptr = DirectoryBuffer; i < SectorCount; i++, Ptr = (PVOID)((ULONG_PTR)Ptr + SECTORSIZE)) { if (!MachDiskReadLogicalSectors(IsoDriveNumber, DirectoryStartSector + i, 1, (PVOID)DISKREADBUFFER)) { @@ -377,14 +377,14 @@ { return FALSE; } - RtlCopyMemory(Buffer, ((PVOID)DISKREADBUFFER + OffsetInSector), LengthInSector); + RtlCopyMemory(Buffer, (PVOID)((ULONG_PTR)DISKREADBUFFER + OffsetInSector), LengthInSector); if (BytesRead != NULL) { *BytesRead += LengthInSector; } BytesToRead -= LengthInSector; IsoFileInfo->FilePointer += LengthInSector; - Buffer += LengthInSector; + Buffer = (PVOID)((ULONG_PTR)Buffer + LengthInSector); } // @@ -417,7 +417,7 @@ } BytesToRead -= SECTORSIZE; IsoFileInfo->FilePointer += SECTORSIZE; - Buffer += SECTORSIZE; + Buffer = (PVOID)((ULONG_PTR)Buffer + SECTORSIZE); } } @@ -442,7 +442,7 @@ } IsoFileInfo->FilePointer += BytesToRead; BytesToRead -= BytesToRead; - Buffer += BytesToRead; + Buffer = (PVOID)((ULONG_PTR)Buffer + BytesToRead); } DbgPrint((DPRINT_FILESYSTEM, "IsoReadFile() done\n")); _____ Modified: trunk/reactos/boot/freeldr/freeldr/linuxboot.c --- trunk/reactos/boot/freeldr/freeldr/linuxboot.c 2005-07-04 22:25:46 UTC (rev 16418) +++ trunk/reactos/boot/freeldr/freeldr/linuxboot.c 2005-07-04 23:05:17 UTC (rev 16419) @@ -346,7 +346,7 @@ // Read in the rest of the linux setup sectors FsSetFilePointer(LinuxKernelFile, 1024); - if (!FsReadFile(LinuxKernelFile, SetupSectorSize - 512, NULL, ((PVOID)LinuxSetupSector) + 512)) + if (!FsReadFile(LinuxKernelFile, SetupSectorSize - 512, NULL, (PVOID)((ULONG_PTR)LinuxSetupSector + 512))) { return FALSE; } @@ -400,7 +400,7 @@ } BytesLoaded += LINUX_READ_CHUNK_SIZE; - LoadAddress += LINUX_READ_CHUNK_SIZE; + LoadAddress = (PVOID)((ULONG_PTR)LoadAddress + LINUX_READ_CHUNK_SIZE); UiDrawProgressBarCenter(BytesLoaded, LinuxKernelSize + LinuxInitrdSize, LinuxBootDescription); } @@ -491,7 +491,7 @@ } BytesLoaded += LINUX_READ_CHUNK_SIZE; - LinuxInitrdLoadAddress += LINUX_READ_CHUNK_SIZE; + LinuxInitrdLoadAddress = (PVOID)((ULONG_PTR)LinuxInitrdLoadAddress + LINUX_READ_CHUNK_SIZE); UiDrawProgressBarCenter(BytesLoaded + LinuxKernelSize, LinuxInitrdSize + LinuxKernelSize, LinuxBootDescription); } _____ Modified: trunk/reactos/boot/freeldr/freeldr/mm/meminit.c --- trunk/reactos/boot/freeldr/freeldr/mm/meminit.c 2005-07-04 22:25:46 UTC (rev 16418) +++ trunk/reactos/boot/freeldr/freeldr/mm/meminit.c 2005-07-04 23:05:17 UTC (rev 16419) @@ -264,7 +264,7 @@ // Mark the pages that the lookup tabel occupies as reserved PageLookupTableStartPage = MmGetPageNumberFromAddress(PageLookupTable); - PageLookupTablePageCount = MmGetPageNumberFromAddress(PageLookupTable + ROUND_UP(TotalPageCount * sizeof(PAGE_LOOKUP_TABLE_ITEM), MM_PAGE_SIZE)) - PageLookupTableStartPage; + PageLookupTablePageCount = MmGetPageNumberFromAddress((PVOID)((ULONG_PTR)PageLookupTable + ROUND_UP(TotalPageCount * sizeof(PAGE_LOOKUP_TABLE_ITEM), MM_PAGE_SIZE))) - PageLookupTableStartPage; DbgPrint((DPRINT_MEMORY, "Marking the page lookup table pages as reserved StartPage: %d PageCount: %d\n", PageLookupTableStartPage, PageLookupTablePageCount)); MmMarkPagesInLookupTable(PageLookupTable, PageLookupTableStartPage, PageLookupTablePageCount, MEMTYPE_RESERVED); } _____ Modified: trunk/reactos/boot/freeldr/freeldr/mm/mm.c --- trunk/reactos/boot/freeldr/freeldr/mm/mm.c 2005-07-04 22:25:46 UTC (rev 16418) +++ trunk/reactos/boot/freeldr/freeldr/mm/mm.c 2005-07-04 23:05:17 UTC (rev 16419) @@ -72,7 +72,7 @@ MemorySize = ROUND_UP(MemorySize, 4); if (MemorySize <= SubAllocationRest) { - MemPointer = SubAllocationPage + MM_PAGE_SIZE - SubAllocationRest; + MemPointer = (PVOID)((ULONG_PTR)SubAllocationPage + MM_PAGE_SIZE - SubAllocationRest); SubAllocationRest -= MemorySize; return MemPointer; } _____ Modified: trunk/reactos/boot/freeldr/freeldr/multiboot.c --- trunk/reactos/boot/freeldr/freeldr/multiboot.c 2005-07-04 22:25:46 UTC (rev 16418) +++ trunk/reactos/boot/freeldr/freeldr/multiboot.c 2005-07-04 23:05:17 UTC (rev 16419) @@ -213,7 +213,7 @@ Ke386SetCr0(Ke386GetCr0() | X86_CR0_PG | X86_CR0_WP); /* Jump to Kernel */ - PagedJump = (ASMCODE)KernelEntryPoint; + PagedJump = (ASMCODE)(PVOID)(KernelEntryPoint); PagedJump(Magic, &LoaderBlock); }
19 years, 6 months
1
0
0
0
[weiden] 16418: some %x -> %p fixes
by weiden@svn.reactos.com
some %x -> %p fixes Modified: trunk/reactos/lib/rtl/env.c Modified: trunk/reactos/lib/rtl/heap.c Modified: trunk/reactos/lib/rtl/image.c Modified: trunk/reactos/lib/rtl/process.c Modified: trunk/reactos/lib/rtl/unicode.c _____ Modified: trunk/reactos/lib/rtl/env.c --- trunk/reactos/lib/rtl/env.c 2005-07-04 22:22:22 UTC (rev 16417) +++ trunk/reactos/lib/rtl/env.c 2005-07-04 22:25:46 UTC (rev 16418) @@ -251,7 +251,7 @@ { PVOID EnvPtr; - DPRINT("NewEnvironment %x OldEnvironment %x\n", + DPRINT("NewEnvironment 0x%p OldEnvironment 0x%p\n", NewEnvironment, OldEnvironment); RtlAcquirePebLock(); _____ Modified: trunk/reactos/lib/rtl/heap.c --- trunk/reactos/lib/rtl/heap.c 2005-07-04 22:22:22 UTC (rev 16417) +++ trunk/reactos/lib/rtl/heap.c 2005-07-04 22:25:46 UTC (rev 16418) @@ -937,7 +937,7 @@ } while ( Frame != 0 && (ULONG)Frame != 0xDEADBEEF && (ULONG)Frame != 0xcdcdcdcd && (ULONG)Frame != 0xcccccccc && i++ < FrameCount ) { - DbgPrint("<%X>", (PVOID)Frame[1]); + DbgPrint("<%p>", (PVOID)Frame[1]); if (Frame[1] == 0xdeadbeef) break; Frame = (PULONG)Frame[0]; _____ Modified: trunk/reactos/lib/rtl/image.c --- trunk/reactos/lib/rtl/image.c 2005-07-04 22:22:22 UTC (rev 16417) +++ trunk/reactos/lib/rtl/image.c 2005-07-04 22:25:46 UTC (rev 16418) @@ -28,12 +28,12 @@ if (DosHeader && DosHeader->e_magic != IMAGE_DOS_SIGNATURE) { DPRINT1("DosHeader->e_magic %x\n", DosHeader->e_magic); - DPRINT1("NtHeader %x\n", (BaseAddress + DosHeader->e_lfanew)); + DPRINT1("NtHeader 0x%p\n", ((ULONG_PTR)BaseAddress + DosHeader->e_lfanew)); } if (DosHeader && DosHeader->e_magic == IMAGE_DOS_SIGNATURE) { - NtHeader = (PIMAGE_NT_HEADERS)(BaseAddress + DosHeader->e_lfanew); + NtHeader = (PIMAGE_NT_HEADERS)((ULONG_PTR)BaseAddress + DosHeader->e_lfanew); if (NtHeader->Signature == IMAGE_NT_SIGNATURE) return NtHeader; } _____ Modified: trunk/reactos/lib/rtl/process.c --- trunk/reactos/lib/rtl/process.c 2005-07-04 22:22:22 UTC (rev 16417) +++ trunk/reactos/lib/rtl/process.c 2005-07-04 22:25:46 UTC (rev 16418) @@ -35,7 +35,7 @@ RtlDeNormalizeProcessParams (Ppb); -// DbgPrint("ImagePathName %x\n", Ppb->ImagePathName.Buffer); +/* DbgPrint("ImagePathName 0x%p\n", Ppb->ImagePathName.Buffer); */ InitializeObjectAttributes(&ObjectAttributes, ImageFileName, _____ Modified: trunk/reactos/lib/rtl/unicode.c --- trunk/reactos/lib/rtl/unicode.c 2005-07-04 22:22:22 UTC (rev 16417) +++ trunk/reactos/lib/rtl/unicode.c 2005-07-04 22:25:46 UTC (rev 16418) @@ -516,7 +516,7 @@ { ULONG DestSize; - DPRINT("RtlInitUnicodeString(DestinationString %x, SourceString %x)\n", + DPRINT("RtlInitUnicodeString(DestinationString 0x%p, SourceString 0x%p)\n", DestinationString, SourceString);
19 years, 6 months
1
0
0
0
[gdalsnes] 16417: fix premature close og reg key
by gdalsnes@svn.reactos.com
fix premature close og reg key Modified: trunk/reactos/lib/setupapi/devinst.c _____ Modified: trunk/reactos/lib/setupapi/devinst.c --- trunk/reactos/lib/setupapi/devinst.c 2005-07-04 22:11:00 UTC (rev 16416) +++ trunk/reactos/lib/setupapi/devinst.c 2005-07-04 22:22:22 UTC (rev 16417) @@ -1391,9 +1391,9 @@ SetupCloseInfFile(hInf); return FALSE; } - RegCloseKey(hClassKey); + /* Try to append a layout file */ #if 0 SetupOpenAppendInfFileW(NULL, hInf, NULL); @@ -1414,6 +1414,7 @@ if (FileQueue == INVALID_HANDLE_VALUE) { SetupCloseInfFile(hInf); + RegCloseKey(hClassKey); return FALSE; } @@ -1441,6 +1442,7 @@ SetupCloseInfFile(hInf); + RegCloseKey(hClassKey); return TRUE; }
19 years, 6 months
1
0
0
0
[weiden] 16416: some %x -> %p fixes
by weiden@svn.reactos.com
some %x -> %p fixes Modified: trunk/reactos/ntoskrnl/cc/copy.c Modified: trunk/reactos/ntoskrnl/cc/fs.c Modified: trunk/reactos/ntoskrnl/cc/pin.c Modified: trunk/reactos/ntoskrnl/cc/view.c Modified: trunk/reactos/ntoskrnl/cm/ntfunc.c Modified: trunk/reactos/ntoskrnl/cm/regfile.c Modified: trunk/reactos/ntoskrnl/cm/registry.c Modified: trunk/reactos/ntoskrnl/cm/regobj.c Modified: trunk/reactos/ntoskrnl/dbgk/debug.c Modified: trunk/reactos/ntoskrnl/ex/event.c Modified: trunk/reactos/ntoskrnl/ex/evtpair.c Modified: trunk/reactos/ntoskrnl/ex/handle.c Modified: trunk/reactos/ntoskrnl/ex/lookas.c Modified: trunk/reactos/ntoskrnl/ex/mutant.c Modified: trunk/reactos/ntoskrnl/ex/resource.c Modified: trunk/reactos/ntoskrnl/ex/timer.c Modified: trunk/reactos/ntoskrnl/fs/filelock.c Modified: trunk/reactos/ntoskrnl/io/device.c Modified: trunk/reactos/ntoskrnl/io/disk.c Modified: trunk/reactos/ntoskrnl/io/driver.c Modified: trunk/reactos/ntoskrnl/io/file.c Modified: trunk/reactos/ntoskrnl/io/fs.c Modified: trunk/reactos/ntoskrnl/io/irp.c Modified: trunk/reactos/ntoskrnl/io/mdl.c Modified: trunk/reactos/ntoskrnl/io/pnpmgr.c Modified: trunk/reactos/ntoskrnl/io/pnproot.c Modified: trunk/reactos/ntoskrnl/io/rawfs.c Modified: trunk/reactos/ntoskrnl/io/share.c Modified: trunk/reactos/ntoskrnl/io/timer.c Modified: trunk/reactos/ntoskrnl/kdbg/kdb.c Modified: trunk/reactos/ntoskrnl/kdbg/kdb_cli.c Modified: trunk/reactos/ntoskrnl/ke/catch.c _____ Modified: trunk/reactos/ntoskrnl/cc/copy.c --- trunk/reactos/ntoskrnl/cc/copy.c 2005-07-04 21:54:36 UTC (rev 16415) +++ trunk/reactos/ntoskrnl/cc/copy.c 2005-07-04 22:11:00 UTC (rev 16416) @@ -315,9 +315,9 @@ PLIST_ENTRY current_entry; PCACHE_SEGMENT current; - DPRINT("CcCopyRead(FileObject %x, FileOffset %x, " - "Length %d, Wait %d, Buffer %x, IoStatus %x)\n", - FileObject, (ULONG)FileOffset->QuadPart, Length, Wait, + DPRINT("CcCopyRead(FileObject 0x%p, FileOffset %I64x, " + "Length %d, Wait %d, Buffer 0x%p, IoStatus 0x%p)\n", + FileObject, FileOffset->QuadPart, Length, Wait, Buffer, IoStatus); Bcb = FileObject->SectionObjectPointer->SharedCacheMap; @@ -429,9 +429,9 @@ PVOID BaseAddress; BOOLEAN Valid; - DPRINT("CcCopyWrite(FileObject %x, FileOffset %x, " - "Length %d, Wait %d, Buffer %x)\n", - FileObject, (ULONG)FileOffset->QuadPart, Length, Wait, Buffer); + DPRINT("CcCopyWrite(FileObject 0x%p, FileOffset %I64x, " + "Length %d, Wait %d, Buffer 0x%p)\n", + FileObject, FileOffset->QuadPart, Length, Wait, Buffer); Bcb = FileObject->SectionObjectPointer->SharedCacheMap; WriteOffset = (ULONG)FileOffset->QuadPart; @@ -611,7 +611,7 @@ IO_STATUS_BLOCK Iosb; KEVENT Event; - DPRINT("CcZeroData(FileObject %x, StartOffset %I64x, EndOffset %I64x, " + DPRINT("CcZeroData(FileObject 0x%p, StartOffset %I64x, EndOffset %I64x, " "Wait %d)\n", FileObject, StartOffset->QuadPart, EndOffset->QuadPart, Wait); _____ Modified: trunk/reactos/ntoskrnl/cc/fs.c --- trunk/reactos/ntoskrnl/cc/fs.c 2005-07-04 21:54:36 UTC (rev 16415) +++ trunk/reactos/ntoskrnl/cc/fs.c 2005-07-04 22:11:00 UTC (rev 16416) @@ -134,7 +134,7 @@ LIST_ENTRY FreeListHead; NTSTATUS Status; - DPRINT("CcSetFileSizes(FileObject %x, FileSizes %x)\n", + DPRINT("CcSetFileSizes(FileObject 0x%p, FileSizes 0x%p)\n", FileObject, FileSizes); DPRINT("AllocationSize %d, FileSize %d, ValidDataLength %d\n", (ULONG)FileSizes->AllocationSize.QuadPart, @@ -196,7 +196,7 @@ Status = CcRosInternalFreeCacheSegment(current); if (!NT_SUCCESS(Status)) { - DPRINT1("CcRosInternalFreeCacheSegment failed, status = %x\n"); + DPRINT1("CcRosInternalFreeCacheSegment failed, status = %x\n", Status); KEBUGCHECK(0); } } _____ Modified: trunk/reactos/ntoskrnl/cc/pin.c --- trunk/reactos/ntoskrnl/cc/pin.c 2005-07-04 21:54:36 UTC (rev 16415) +++ trunk/reactos/ntoskrnl/cc/pin.c 2005-07-04 22:11:00 UTC (rev 16416) @@ -39,17 +39,17 @@ PINTERNAL_BCB iBcb; ULONG ROffset; - DPRINT("CcMapData(FileObject %x, FileOffset %d, Length %d, Wait %d," - " pBcb %x, pBuffer %x)\n", FileObject, (ULONG)FileOffset->QuadPart, + DPRINT("CcMapData(FileObject 0x%p, FileOffset %I64x, Length %d, Wait %d," + " pBcb 0x%p, pBuffer 0x%p)\n", FileObject, FileOffset->QuadPart, Length, Wait, pBcb, pBuffer); ReadOffset = (ULONG)FileOffset->QuadPart; Bcb = FileObject->SectionObjectPointer->SharedCacheMap; ASSERT(Bcb); - DPRINT("AllocationSize %d, FileSize %d\n", - (ULONG)Bcb->AllocationSize.QuadPart, - (ULONG)Bcb->FileSize.QuadPart); + DPRINT("AllocationSize %I64x, FileSize %I64x\n", + Bcb->AllocationSize.QuadPart, + Bcb->FileSize.QuadPart); if (ReadOffset % Bcb->CacheSegmentSize + Length > Bcb->CacheSegmentSize) { _____ Modified: trunk/reactos/ntoskrnl/cc/view.c --- trunk/reactos/ntoskrnl/cc/view.c 2005-07-04 21:54:36 UTC (rev 16415) +++ trunk/reactos/ntoskrnl/cc/view.c 2005-07-04 22:11:00 UTC (rev 16416) @@ -295,7 +295,7 @@ ASSERT(Bcb); - DPRINT("CcReleaseCacheSegment(Bcb %x, CacheSeg %x, Valid %d)\n", + DPRINT("CcReleaseCacheSegment(Bcb 0x%p, CacheSeg 0x%p, Valid %d)\n", Bcb, CacheSeg, Valid); CacheSeg->Valid = Valid; @@ -340,7 +340,7 @@ ASSERT(Bcb); - DPRINT("CcRosLookupCacheSegment(Bcb %x, FileOffset %d)\n", Bcb, FileOffset); + DPRINT("CcRosLookupCacheSegment(Bcb -x%p, FileOffset %d)\n", Bcb, FileOffset); KeAcquireSpinLock(&Bcb->BcbLock, &oldIrql); current_entry = Bcb->BcbSegmentListHead.Flink; @@ -370,7 +370,7 @@ ASSERT(Bcb); - DPRINT("CcRosMarkDirtyCacheSegment(Bcb %x, FileOffset %d)\n", Bcb, FileOffset); + DPRINT("CcRosMarkDirtyCacheSegment(Bcb 0x%p, FileOffset %d)\n", Bcb, FileOffset); CacheSeg = CcRosLookupCacheSegment(Bcb, FileOffset); if (CacheSeg == NULL) @@ -407,7 +407,7 @@ ASSERT(Bcb); - DPRINT("CcRosUnmapCacheSegment(Bcb %x, FileOffset %d, NowDirty %d)\n", + DPRINT("CcRosUnmapCacheSegment(Bcb 0x%p, FileOffset %d, NowDirty %d)\n", Bcb, FileOffset, NowDirty); CacheSeg = CcRosLookupCacheSegment(Bcb, FileOffset); @@ -760,7 +760,7 @@ PFN_TYPE Page; KIRQL oldIrql; #endif - DPRINT("Freeing cache segment %x\n", CacheSeg); + DPRINT("Freeing cache segment 0x%p\n", CacheSeg); #ifdef CACHE_BITMAP RegionSize = CacheSeg->Bcb->CacheSegmentSize / PAGE_SIZE; @@ -804,7 +804,7 @@ ASSERT(Bcb); - DPRINT("CcRosFreeCacheSegment(Bcb %x, CacheSeg %x)\n", + DPRINT("CcRosFreeCacheSegment(Bcb 0x%p, CacheSeg 0x%p)\n", Bcb, CacheSeg); ExAcquireFastMutex(&ViewLock); @@ -840,7 +840,7 @@ NTSTATUS Status; KIRQL oldIrql; - DPRINT("CcFlushCache(SectionObjectPointers %x, FileOffset %x, Length %d, IoStatus %x)\n", + DPRINT("CcFlushCache(SectionObjectPointers 0x%p, FileOffset 0x%p, Length %d, IoStatus 0x%p)\n", SectionObjectPointers, FileOffset, Length, IoStatus); if (SectionObjectPointers && SectionObjectPointers->SharedCacheMap) @@ -1118,7 +1118,7 @@ PBCB Bcb; Bcb = FileObject->SectionObjectPointer->SharedCacheMap; - DPRINT("CcRosInitializeFileCache(FileObject %x, *Bcb %x, CacheSegmentSize %d)\n", + DPRINT("CcRosInitializeFileCache(FileObject 0x%p, Bcb 0x%p, CacheSegmentSize %d)\n", FileObject, Bcb, CacheSegmentSize); ExAcquireFastMutex(&ViewLock); _____ Modified: trunk/reactos/ntoskrnl/cm/ntfunc.c --- trunk/reactos/ntoskrnl/cm/ntfunc.c 2005-07-04 21:54:36 UTC (rev 16415) +++ trunk/reactos/ntoskrnl/cm/ntfunc.c 2005-07-04 22:11:00 UTC (rev 16416) @@ -49,8 +49,8 @@ PAGED_CODE(); - DPRINT("CmpFindObject(ObjectAttributes %x, ReturnedObject %x, " - "RemainingPath %x)\n",ObjectAttributes,ReturnedObject,RemainingPath); + DPRINT("CmpFindObject(ObjectAttributes 0x%p, ReturnedObject 0x%p, " + "RemainingPath 0x%p)\n",ObjectAttributes,ReturnedObject,RemainingPath); DPRINT("ObjectAttributes->ObjectName %wZ\n", ObjectAttributes->ObjectName); @@ -326,7 +326,7 @@ PAGED_CODE(); - DPRINT("NtCreateKey (Name %wZ KeyHandle %x Root %x)\n", + DPRINT("NtCreateKey (Name %wZ KeyHandle 0x%p Root 0x%p)\n", ObjectAttributes->ObjectName, KeyHandle, ObjectAttributes->RootDirectory); @@ -386,7 +386,7 @@ } } - DPRINT("RemainingPath %S ParentObject %x\n", RemainingPath.Buffer, Object); + DPRINT("RemainingPath %S ParentObject 0x%p\n", RemainingPath.Buffer, Object); Status = ObCreateObject(ExGetPreviousMode(), CmiKeyType, @@ -511,7 +511,7 @@ PAGED_CODE(); - DPRINT("NtDeleteKey(KeyHandle %x) called\n", KeyHandle); + DPRINT("NtDeleteKey(KeyHandle 0x%p) called\n", KeyHandle); PreviousMode = ExGetPreviousMode(); @@ -599,7 +599,7 @@ PreviousMode = ExGetPreviousMode(); - DPRINT("KH %x I %d KIC %x KI %x L %d RL %x\n", + DPRINT("KH 0x%p I %d KIC %x KI 0x%p L %d RL 0x%p\n", KeyHandle, Index, KeyInformationClass, @@ -947,7 +947,7 @@ PAGED_CODE(); - DPRINT("KH %x I %d KVIC %x KVI %x L %d RL %x\n", + DPRINT("KH 0x%p I %d KVIC %x KVI 0x%p L %d RL 0x%p\n", KeyHandle, Index, KeyValueInformationClass, @@ -1241,7 +1241,7 @@ PAGED_CODE(); - DPRINT("NtOpenKey(KH %x DA %x OA %x OA->ON '%wZ'\n", + DPRINT("NtOpenKey(KH 0x%p DA %x OA 0x%p OA->ON '%wZ'\n", KeyHandle, DesiredAccess, ObjectAttributes, @@ -1358,7 +1358,7 @@ PAGED_CODE(); - DPRINT("NtQueryKey(KH %x KIC %x KI %x L %d RL %x)\n", + DPRINT("NtQueryKey(KH 0x%p KIC %x KI 0x%p L %d RL 0x%p)\n", KeyHandle, KeyInformationClass, KeyInformation, @@ -1568,7 +1568,7 @@ PAGED_CODE(); - DPRINT("NtQueryValueKey(KeyHandle %x ValueName %S Length %x)\n", + DPRINT("NtQueryValueKey(KeyHandle 0x%p ValueName %S Length %x)\n", KeyHandle, ValueName->Buffer, Length); /* Verify that the handle is valid and is a registry key */ @@ -1810,7 +1810,7 @@ PAGED_CODE(); - DPRINT("NtSetValueKey(KeyHandle %x ValueName '%wZ' Type %d)\n", + DPRINT("NtSetValueKey(KeyHandle 0x%p ValueName '%wZ' Type %d)\n", KeyHandle, ValueName, Type); DesiredAccess = KEY_SET_VALUE; _____ Modified: trunk/reactos/ntoskrnl/cm/regfile.c --- trunk/reactos/ntoskrnl/cm/regfile.c 2005-07-04 21:54:36 UTC (rev 16415) +++ trunk/reactos/ntoskrnl/cm/regfile.c 2005-07-04 22:11:00 UTC (rev 16416) @@ -1068,7 +1068,7 @@ RtlZeroMemory (Hive, sizeof(REGISTRY_HIVE)); - DPRINT("Hive %x\n", Hive); + DPRINT("Hive 0x%p\n", Hive); Hive->HiveHeader = (PHIVE_HEADER)ExAllocatePool (NonPagedPool, sizeof(HIVE_HEADER)); @@ -1138,7 +1138,7 @@ RtlZeroMemory (Hive, sizeof(REGISTRY_HIVE)); - DPRINT ("Hive %x\n", Hive); + DPRINT ("Hive 0x%p\n", Hive); Hive->HiveHeader = (PHIVE_HEADER)ExAllocatePool (NonPagedPool, REG_BLOCK_SIZE); @@ -1151,7 +1151,7 @@ RtlZeroMemory (Hive->HiveHeader, REG_BLOCK_SIZE); - DPRINT ("HiveHeader %x\n", Hive->HiveHeader); + DPRINT ("HiveHeader 0x%p\n", Hive->HiveHeader); Hive->Flags = HIVE_NO_FILE; @@ -1260,7 +1260,7 @@ RtlZeroMemory (Hive, sizeof(REGISTRY_HIVE)); - DPRINT ("Hive %x\n", Hive); + DPRINT ("Hive 0x%p\n", Hive); Hive->Flags = (Flags & REG_NO_LAZY_FLUSH) ? HIVE_NO_SYNCH : 0; Hive->HiveHeader = (PHIVE_HEADER)ExAllocatePool(NonPagedPool, _____ Modified: trunk/reactos/ntoskrnl/cm/registry.c --- trunk/reactos/ntoskrnl/cm/registry.c 2005-07-04 21:54:36 UTC (rev 16415) +++ trunk/reactos/ntoskrnl/cm/registry.c 2005-07-04 22:11:00 UTC (rev 16416) @@ -1270,7 +1270,7 @@ ExReleaseResourceLite(&CmiRegistryLock); KeLeaveCriticalRegion(); - DPRINT("DeferredContext %x\n", DeferredContext); + DPRINT("DeferredContext 0x%p\n", DeferredContext); ExFreePool(DeferredContext); DPRINT("CmiHiveSyncRoutine() done\n"); @@ -1297,7 +1297,7 @@ CmiHiveSyncRoutine, WorkQueueItem); - DPRINT("DeferredContext %x\n", WorkQueueItem); + DPRINT("DeferredContext 0x%p\n", WorkQueueItem); ExQueueWorkItem(WorkQueueItem, CriticalWorkQueue); } _____ Modified: trunk/reactos/ntoskrnl/cm/regobj.c --- trunk/reactos/ntoskrnl/cm/regobj.c 2005-07-04 21:54:36 UTC (rev 16415) +++ trunk/reactos/ntoskrnl/cm/regobj.c 2005-07-04 22:11:00 UTC (rev 16416) @@ -196,7 +196,7 @@ RtlpCreateUnicodeString(&FoundObject->Name, KeyName.Buffer, NonPagedPool); CmiAddKeyToList(ParsedKey, FoundObject); - DPRINT("Created object 0x%x\n", FoundObject); + DPRINT("Created object 0x%p\n", FoundObject); } else { @@ -578,7 +578,7 @@ /* to allow a dichotomic search */ ParentKey->SubKeys[ParentKey->NumberOfSubKeys++] = NewKey; - DPRINT("Reference parent key: 0x%x\n", ParentKey); + DPRINT("Reference parent key: 0x%p\n", ParentKey); ObReferenceObjectByPointer(ParentKey, STANDARD_RIGHTS_REQUIRED, _____ Modified: trunk/reactos/ntoskrnl/dbgk/debug.c --- trunk/reactos/ntoskrnl/dbgk/debug.c 2005-07-04 21:54:36 UTC (rev 16415) +++ trunk/reactos/ntoskrnl/dbgk/debug.c 2005-07-04 22:11:00 UTC (rev 16416) @@ -29,7 +29,7 @@ NTSTATUS Status = STATUS_SUCCESS; PAGED_CODE(); - DPRINT("NtCreateDebugObject(0x%x, 0x%x, 0x%x)\n", DebugHandle, DesiredAccess, ObjectAttributes); + DPRINT("NtCreateDebugObject(0x%p, 0x%x, 0x%p)\n", DebugHandle, DesiredAccess, ObjectAttributes); /* Check Output Safety */ if(PreviousMode != KernelMode) { _____ Modified: trunk/reactos/ntoskrnl/ex/event.c --- trunk/reactos/ntoskrnl/ex/event.c 2005-07-04 21:54:36 UTC (rev 16415) +++ trunk/reactos/ntoskrnl/ex/event.c 2005-07-04 22:11:00 UTC (rev 16416) @@ -103,7 +103,7 @@ NTSTATUS Status = STATUS_SUCCESS; PAGED_CODE(); - DPRINT("NtCreateEvent(0x%x, 0x%x, 0x%x)\n", EventHandle, DesiredAccess, ObjectAttributes); + DPRINT("NtCreateEvent(0x%p, 0x%x, 0x%p)\n", EventHandle, DesiredAccess, ObjectAttributes); /* Check Output Safety */ if(PreviousMode != KernelMode) { @@ -183,7 +183,7 @@ NTSTATUS Status = STATUS_SUCCESS; PAGED_CODE(); - DPRINT("NtOpenEvent(0x%x, 0x%x, 0x%x)\n", EventHandle, DesiredAccess, ObjectAttributes); + DPRINT("NtOpenEvent(0x%p, 0x%x, 0x%p)\n", EventHandle, DesiredAccess, ObjectAttributes); /* Check Output Safety */ if(PreviousMode != KernelMode) { @@ -314,7 +314,7 @@ PEVENT_BASIC_INFORMATION BasicInfo = (PEVENT_BASIC_INFORMATION)EventInformation; PAGED_CODE(); - DPRINT("NtQueryEvent(0x%x, 0x%x, 0x%x)\n", EventHandle, EventInformationClass); + DPRINT("NtQueryEvent(0x%p, 0x%x)\n", EventHandle, EventInformationClass); /* Check buffers and class validity */ DefaultQueryInfoBufferCheck(EventInformationClass, _____ Modified: trunk/reactos/ntoskrnl/ex/evtpair.c --- trunk/reactos/ntoskrnl/ex/evtpair.c 2005-07-04 21:54:36 UTC (rev 16415) +++ trunk/reactos/ntoskrnl/ex/evtpair.c 2005-07-04 22:11:00 UTC (rev 16416) @@ -62,7 +62,7 @@ NTSTATUS Status = STATUS_SUCCESS; PAGED_CODE(); - DPRINT("NtCreateEventPair: %x\n", EventPairHandle); + DPRINT("NtCreateEventPair: 0x%p\n", EventPairHandle); /* Check Output Safety */ if(PreviousMode == UserMode) { @@ -194,7 +194,7 @@ NTSTATUS Status; PAGED_CODE(); - DPRINT("NtSetHighEventPair(EventPairHandle %x)\n", EventPairHandle); + DPRINT("NtSetHighEventPair(EventPairHandle 0x%p)\n", EventPairHandle); /* Open the Object */ Status = ObReferenceObjectByHandle(EventPairHandle, @@ -227,7 +227,7 @@ NTSTATUS Status; PAGED_CODE(); - DPRINT("NtSetHighWaitLowEventPair(EventPairHandle %x)\n", EventPairHandle); + DPRINT("NtSetHighWaitLowEventPair(EventPairHandle 0x%p)\n", EventPairHandle); /* Open the Object */ Status = ObReferenceObjectByHandle(EventPairHandle, @@ -270,7 +270,7 @@ PreviousMode = ExGetPreviousMode(); - DPRINT1("NtSetHighEventPair(EventPairHandle %x)\n", EventPairHandle); + DPRINT1("NtSetHighEventPair(EventPairHandle 0x%p)\n", EventPairHandle); /* Open the Object */ Status = ObReferenceObjectByHandle(EventPairHandle, @@ -303,7 +303,7 @@ NTSTATUS Status; PAGED_CODE(); - DPRINT("NtSetHighWaitLowEventPair(EventPairHandle %x)\n", EventPairHandle); + DPRINT("NtSetHighWaitLowEventPair(EventPairHandle 0x%p)\n", EventPairHandle); /* Open the Object */ Status = ObReferenceObjectByHandle(EventPairHandle, @@ -344,7 +344,7 @@ NTSTATUS Status; PAGED_CODE(); - DPRINT("NtSetHighWaitLowEventPair(EventPairHandle %x)\n", EventPairHandle); + DPRINT("NtSetHighWaitLowEventPair(EventPairHandle 0x%p)\n", EventPairHandle); /* Open the Object */ Status = ObReferenceObjectByHandle(EventPairHandle, @@ -381,7 +381,7 @@ NTSTATUS Status; PAGED_CODE(); - DPRINT("NtSetHighWaitLowEventPair(EventPairHandle %x)\n", EventPairHandle); + DPRINT("NtSetHighWaitLowEventPair(EventPairHandle 0x%p)\n", EventPairHandle); /* Open the Object */ Status = ObReferenceObjectByHandle(EventPairHandle, _____ Modified: trunk/reactos/ntoskrnl/ex/handle.c --- trunk/reactos/ntoskrnl/ex/handle.c 2005-07-04 21:54:36 UTC (rev 16415) +++ trunk/reactos/ntoskrnl/ex/handle.c 2005-07-04 22:11:00 UTC (rev 16416) @@ -166,7 +166,7 @@ PAGED_CODE(); - DPRINT("Entering handle table entry 0x%x lock...\n", Entry); + DPRINT("Entering handle table entry 0x%p lock...\n", Entry); ASSERT(HandleTable); ASSERT(Entry); @@ -177,7 +177,7 @@ if(!Current) { - DPRINT("Attempted to lock empty handle table entry 0x%x or handle table shut down\n", Entry); + DPRINT("Attempted to lock empty handle table entry 0x%p or handle table shut down\n", Entry); break; } @@ -188,7 +188,7 @@ (PVOID)New, (PVOID)Current) == (PVOID)Current) { - DPRINT("SUCCESS handle table 0x%x entry 0x%x lock\n", HandleTable, Entry); + DPRINT("SUCCESS handle table 0x%p entry 0x%p lock\n", HandleTable, Entry); /* we acquired the lock */ return TRUE; } @@ -399,7 +399,7 @@ else { freehandletable: - DPRINT1("Failed to duplicate handle table 0x%x\n", SourceHandleTable); + DPRINT1("Failed to duplicate handle table 0x%p\n", SourceHandleTable); ExReleaseHandleTableLock(SourceHandleTable); @@ -501,7 +501,7 @@ ASSERT(Handle); ASSERT(KeGetCurrentThread() != NULL); - DPRINT("HT[0x%x]: HandleCount: %d\n", HandleTable, HandleTable->HandleCount); + DPRINT("HT[0x%p]: HandleCount: %d\n", HandleTable, HandleTable->HandleCount); if(HandleTable->HandleCount < EX_MAX_HANDLES) { @@ -549,7 +549,7 @@ ASSERT(ELI_FROM_HANDLE(HandleTable->NextIndexNeedingPool) == 0); - DPRINT("HandleTable->Table[%d] == 0x%x\n", tli, HandleTable->Table[tli]); + DPRINT("HandleTable->Table[%d] == 0x%p\n", tli, HandleTable->Table[tli]); /* allocate a middle level entry list if required */ nmtbl = HandleTable->Table[tli]; @@ -592,7 +592,7 @@ ASSERT(nmtbl[mli] == NULL); } - DPRINT("HandleTable->Table[%d][%d] == 0x%x\n", tli, mli, nmtbl[mli]); + DPRINT("HandleTable->Table[%d][%d] == 0x%p\n", tli, mli, nmtbl[mli]); if(HandleTable->QuotaProcess != NULL) { @@ -660,7 +660,7 @@ } else { - DPRINT1("Can't allocate any more handles in handle table 0x%x!\n", HandleTable); + DPRINT1("Can't allocate any more handles in handle table 0x%p!\n", HandleTable); } return Entry; @@ -677,7 +677,7 @@ ASSERT(Entry); ASSERT(IS_VALID_EX_HANDLE(Handle)); - DPRINT("ExpFreeHandleTableEntry HT:0x%x Entry:0x%x\n", HandleTable, Entry); + DPRINT("ExpFreeHandleTableEntry HT:0x%p Entry:0x%p\n", HandleTable, Entry); /* automatically unlock the entry if currently locked. We however don't notify anyone who waited on the handle because we're holding an exclusive lock after @@ -713,7 +713,7 @@ mlp != NULL && mlp[mli] != NULL && mlp[mli][eli].u1.Object != NULL) { Entry = &mlp[mli][eli]; - DPRINT("handle lookup 0x%x -> entry 0x%x [HT:0x%x] ptr: 0x%x\n", Handle, Entry, HandleTable, mlp[mli][eli].u1.Object); + DPRINT("handle lookup 0x%x -> entry 0x%p [HT:0x%p] ptr: 0x%p\n", Handle, Entry, HandleTable, mlp[mli][eli].u1.Object); } } else @@ -732,7 +732,7 @@ PAGED_CODE(); - DPRINT("Entering handle table entry 0x%x lock...\n", Entry); + DPRINT("Entering handle table entry 0x%p lock...\n", Entry); ASSERT(HandleTable); ASSERT(Entry); @@ -743,7 +743,7 @@ if(!Current || (HandleTable->Flags & EX_HANDLE_TABLE_CLOSING)) { - DPRINT("Attempted to lock empty handle table entry 0x%x or handle table shut down\n", Entry); + DPRINT("Attempted to lock empty handle table entry 0x%p or handle table shut down\n", Entry); break; } @@ -754,7 +754,7 @@ (PVOID)New, (PVOID)Current) == (PVOID)Current) { - DPRINT("SUCCESS handle table 0x%x entry 0x%x lock\n", HandleTable, Entry); + DPRINT("SUCCESS handle table 0x%p entry 0x%p lock\n", HandleTable, Entry); /* we acquired the lock */ return TRUE; } @@ -785,7 +785,7 @@ ASSERT(HandleTable); ASSERT(Entry); - DPRINT("ExUnlockHandleTableEntry HT:0x%x Entry:0x%x\n", HandleTable, Entry); + DPRINT("ExUnlockHandleTableEntry HT:0x%p Entry:0x%p\n", HandleTable, Entry); Current = (volatile ULONG_PTR)Entry->u1.Object; @@ -885,7 +885,7 @@ /* This routine requires the entry to be locked */ ASSERT((ULONG_PTR)Entry->u1.Object & EX_HANDLE_ENTRY_LOCKED); - DPRINT("DestroyHandleByEntry HT:0x%x Entry:0x%x\n", HandleTable, Entry); + DPRINT("DestroyHandleByEntry HT:0x%p Entry:0x%p\n", HandleTable, Entry); KeEnterCriticalRegion(); ExAcquireHandleTableLockExclusive(HandleTable); @@ -914,7 +914,7 @@ Handle); if (HandleTableEntry != NULL && ExLockHandleTableEntry(HandleTable, HandleTableEntry)) { - DPRINT("ExMapHandleToPointer HT:0x%x Entry:0x%x locked\n", HandleTable, HandleTableEntry); + DPRINT("ExMapHandleToPointer HT:0x%p Entry:0x%p locked\n", HandleTable, HandleTableEntry); return HandleTableEntry; } _____ Modified: trunk/reactos/ntoskrnl/ex/lookas.c --- trunk/reactos/ntoskrnl/ex/lookas.c 2005-07-04 21:54:36 UTC (rev 16415) +++ trunk/reactos/ntoskrnl/ex/lookas.c 2005-07-04 22:11:00 UTC (rev 16416) @@ -139,7 +139,7 @@ ULONG Tag, USHORT Depth) { - DPRINT("Initializing nonpaged lookaside list at 0x%X\n", Lookaside); + DPRINT("Initializing nonpaged lookaside list at 0x%p\n", Lookaside); /* Initialize the Header */ ExInitializeSListHead(&Lookaside->L.ListHead); @@ -194,7 +194,7 @@ ULONG Tag, USHORT Depth) { - DPRINT("Initializing paged lookaside list at 0x%X\n", Lookaside); + DPRINT("Initializing paged lookaside list at 0x%p\n", Lookaside); /* Initialize the Header */ ExInitializeSListHead(&Lookaside->L.ListHead); _____ Modified: trunk/reactos/ntoskrnl/ex/mutant.c --- trunk/reactos/ntoskrnl/ex/mutant.c 2005-07-04 21:54:36 UTC (rev 16415) +++ trunk/reactos/ntoskrnl/ex/mutant.c 2005-07-04 22:11:00 UTC (rev 16416) @@ -40,7 +40,7 @@ ExpDeleteMutant(PVOID ObjectBody) { - DPRINT("ExpDeleteMutant(ObjectBody %x)\n", ObjectBody); + DPRINT("ExpDeleteMutant(ObjectBody 0x%p)\n", ObjectBody); /* Make sure to release the Mutant */ KeReleaseMutant((PKMUTANT)ObjectBody, @@ -87,7 +87,7 @@ NTSTATUS Status = STATUS_SUCCESS; PAGED_CODE(); - DPRINT("NtCreateMutant(0x%x, 0x%x, 0x%x)\n", MutantHandle, DesiredAccess, ObjectAttributes); + DPRINT("NtCreateMutant(0x%p, 0x%x, 0x%p)\n", MutantHandle, DesiredAccess, ObjectAttributes); /* Check Output Safety */ if(PreviousMode == UserMode) { @@ -166,7 +166,7 @@ NTSTATUS Status = STATUS_SUCCESS; PAGED_CODE(); - DPRINT("NtOpenMutant(0x%x, 0x%x, 0x%x)\n", MutantHandle, DesiredAccess, ObjectAttributes); + DPRINT("NtOpenMutant(0x%p, 0x%x, 0x%p)\n", MutantHandle, DesiredAccess, ObjectAttributes); /* Check Output Safety */ if(PreviousMode == UserMode) { @@ -296,7 +296,7 @@ PreviousMode = ExGetPreviousMode(); - DPRINT("NtReleaseMutant(MutantHandle 0%x PreviousCount 0%x)\n", + DPRINT("NtReleaseMutant(MutantHandle 0x%p PreviousCount 0x%p)\n", MutantHandle, PreviousCount); _____ Modified: trunk/reactos/ntoskrnl/ex/resource.c --- trunk/reactos/ntoskrnl/ex/resource.c 2005-07-04 21:54:36 UTC (rev 16415) +++ trunk/reactos/ntoskrnl/ex/resource.c 2005-07-04 22:11:00 UTC (rev 16416) @@ -100,7 +100,7 @@ { KIRQL oldIrql; - DPRINT("ExAcquireResourceExclusiveLite(Resource %x, Wait %d)\n", + DPRINT("ExAcquireResourceExclusiveLite(Resource 0x%p, Wait %d)\n", Resource, Wait); ASSERT_IRQL_LESS(DISPATCH_LEVEL); @@ -222,7 +222,7 @@ POWNER_ENTRY freeEntry; ULONG i = 0; - DPRINT("EiAddSharedOwner(Resource %x)\n", Resource); + DPRINT("EiAddSharedOwner(Resource 0x%p)\n", Resource); if (Resource->ActiveCount == 0) { @@ -292,7 +292,7 @@ } } - DPRINT("Found free entry %x\n", freeEntry); + DPRINT("Found free entry 0x%p\n", freeEntry); if (!freeEntry) { @@ -346,7 +346,7 @@ { KIRQL oldIrql; - DPRINT("ExAcquireResourceSharedLite(Resource %x, Wait %d)\n", + DPRINT("ExAcquireResourceSharedLite(Resource 0x%p, Wait %d)\n", Resource, Wait); ASSERT_IRQL_LESS(DISPATCH_LEVEL); @@ -438,7 +438,7 @@ ULONG oldWaiters; KIRQL oldIrql; - DPRINT("ExConvertExclusiveToSharedLite(Resource %x)\n", Resource); + DPRINT("ExConvertExclusiveToSharedLite(Resource 0x%p)\n", Resource); KeAcquireSpinLock(&Resource->SpinLock, &oldIrql); @@ -519,7 +519,7 @@ { KIRQL oldIrql; - DPRINT("ExAcquireSharedStarveExclusive(Resource %x, Wait %d)\n", + DPRINT("ExAcquireSharedStarveExclusive(Resource 0x%p, Wait %d)\n", Resource, Wait); KeAcquireSpinLock(&Resource->SpinLock, &oldIrql); @@ -610,7 +610,7 @@ PERESOURCE Resource ) { - DPRINT("ExDeleteResourceLite(Resource %x)\n", Resource); + DPRINT("ExDeleteResourceLite(Resource 0x%p)\n", Resource); if (Resource->OwnerTable) ExFreePool(Resource->OwnerTable); if (Resource->SharedWaiters) ExFreePool(Resource->SharedWaiters); if (Resource->ExclusiveWaiters) ExFreePool(Resource->ExclusiveWaiters); @@ -652,7 +652,7 @@ NTSTATUS STDCALL ExInitializeResourceLite (PERESOURCE Resource) { - DPRINT("ExInitializeResourceLite(Resource %x)\n", Resource); + DPRINT("ExInitializeResourceLite(Resource 0x%p)\n", Resource); memset(Resource,0,sizeof(ERESOURCE)); Resource->NumberOfSharedWaiters = 0; Resource->NumberOfExclusiveWaiters = 0; @@ -822,7 +822,7 @@ { KIRQL oldIrql; - DPRINT("ExReleaseResourceForThreadLite(Resource %x, ResourceThreadId %x)\n", + DPRINT("ExReleaseResourceForThreadLite(Resource 0x%p, ResourceThreadId 0x%p)\n", Resource, ResourceThreadId); ASSERT(KeGetCurrentIrql() <= DISPATCH_LEVEL); _____ Modified: trunk/reactos/ntoskrnl/ex/timer.c --- trunk/reactos/ntoskrnl/ex/timer.c 2005-07-04 21:54:36 UTC (rev 16415) +++ trunk/reactos/ntoskrnl/ex/timer.c 2005-07-04 22:11:00 UTC (rev 16416) @@ -78,7 +78,7 @@ ASSERT (Timer->ApcAssociated); Timer->ApcAssociated = FALSE; - DPRINT("Timer, ThreadList: %x, %x\n", Timer, Thread); + DPRINT("Timer, ThreadList: 0x%p, 0x%p\n", Timer, Thread); /* Unlock the list */ KeReleaseSpinLockFromDpcLevel(&Thread->ActiveTimerListLock); @@ -113,7 +113,7 @@ KIRQL OldIrql; PETIMER Timer = ObjectBody; - DPRINT("ExpDeleteTimer(Timer: %x)\n", Timer); + DPRINT("ExpDeleteTimer(Timer: 0x%p)\n", Timer); /* Lock the Wake List */ KeAcquireSpinLock(&ExpWakeListLock, &OldIrql); @@ -145,7 +145,7 @@ PETIMER Timer; KIRQL OldIrql; - DPRINT("ExpTimerDpcRoutine(Dpc: %x)\n", Dpc); + DPRINT("ExpTimerDpcRoutine(Dpc: 0x%p)\n", Dpc); /* Get the Timer Object */ Timer = (PETIMER)DeferredContext; @@ -182,7 +182,7 @@ /* We need to find out which Timer we are */ Timer = CONTAINING_RECORD(Apc, ETIMER, TimerApc); - DPRINT("ExpTimerApcKernelRoutine(Apc: %x. Timer: %x)\n", Apc, Timer); + DPRINT("ExpTimerApcKernelRoutine(Apc: 0x%p. Timer: 0x%p)\n", Apc, Timer); /* Lock the Timer */ KeAcquireSpinLock(&Timer->Lock, &OldIrql); @@ -259,7 +259,7 @@ NTSTATUS Status = STATUS_SUCCESS; PAGED_CODE(); - DPRINT("NtCancelTimer(0x%x, 0x%x)\n", TimerHandle, CurrentState); + DPRINT("NtCancelTimer(0x%p, 0x%x)\n", TimerHandle, CurrentState); /* Check Parameter Validity */ if(CurrentState != NULL && PreviousMode != KernelMode) { @@ -287,7 +287,7 @@ /* Check for success */ if(NT_SUCCESS(Status)) { - DPRINT("Timer Referencced: %x\n", Timer); + DPRINT("Timer Referenced: 0x%p\n", Timer); /* Lock the Timer */ KeAcquireSpinLock(&Timer->Lock, &OldIrql); @@ -300,7 +300,7 @@ * Get the Thread. */ TimerThread = CONTAINING_RECORD(Timer->TimerApc.Thread, ETHREAD, Tcb); - DPRINT("Removing from Thread: %x\n", TimerThread); + DPRINT("Removing from Thread: 0x%p\n", TimerThread); /* Lock its active list */ KeAcquireSpinLockAtDpcLevel(&TimerThread->ActiveTimerListLock); @@ -371,7 +371,7 @@ NTSTATUS Status = STATUS_SUCCESS; PAGED_CODE(); - DPRINT("NtCreateTimer(Handle: %x, Type: %d)\n", TimerHandle, TimerType); + DPRINT("NtCreateTimer(Handle: 0x%p, Type: %d)\n", TimerHandle, TimerType); /* Check Parameter Validity */ if (PreviousMode != KernelMode) { @@ -405,7 +405,7 @@ if(NT_SUCCESS(Status)) { /* Initialize the Kernel Timer */ - DPRINT("Initializing Timer: %x\n", Timer); + DPRINT("Initializing Timer: 0x%p\n", Timer); KeInitializeTimerEx(&Timer->KeTimer, TimerType); /* Initialize the Timer Lock */ @@ -456,7 +456,7 @@ NTSTATUS Status = STATUS_SUCCESS; PAGED_CODE(); - DPRINT("NtOpenTimer(TimerHandle: %x)\n", TimerHandle); + DPRINT("NtOpenTimer(TimerHandle: 0x%p)\n", TimerHandle); /* Check Parameter Validity */ if (PreviousMode != KernelMode) { @@ -519,7 +519,7 @@ PTIMER_BASIC_INFORMATION BasicInfo = (PTIMER_BASIC_INFORMATION)TimerInformation; PAGED_CODE(); - DPRINT("NtQueryTimer(TimerHandle: %x, Class: %d)\n", TimerHandle, TimerInformationClass); + DPRINT("NtQueryTimer(TimerHandle: 0x%p, Class: %d)\n", TimerHandle, TimerInformationClass); /* Check Validity */ DefaultQueryInfoBufferCheck(TimerInformationClass, @@ -550,7 +550,7 @@ _SEH_TRY { /* FIXME: Interrupt correction based on Interrupt Time */ - DPRINT("Returning Information for Timer: %x. Time Remaining: %d\n", Timer, Timer->KeTimer.DueTime.QuadPart); + DPRINT("Returning Information for Timer: 0x%p. Time Remaining: %I64x\n", Timer, Timer->KeTimer.DueTime.QuadPart); BasicInfo->TimeRemaining.QuadPart = Timer->KeTimer.DueTime.QuadPart; BasicInfo->SignalState = KeReadStateTimer(&Timer->KeTimer); @@ -591,7 +591,7 @@ NTSTATUS Status = STATUS_SUCCESS; PAGED_CODE(); - DPRINT("NtSetTimer(TimerHandle: %x, DueTime: %d, Apc: %x, Period: %d)\n", TimerHandle, DueTime->QuadPart, TimerApcRoutine, Period); + DPRINT("NtSetTimer(TimerHandle: 0x%p, DueTime: %I64x, Apc: 0x%p, Period: %d)\n", TimerHandle, DueTime->QuadPart, TimerApcRoutine, Period); /* Check Parameter Validity */ if (PreviousMode != KernelMode) { @@ -631,7 +631,7 @@ if (NT_SUCCESS(Status)) { /* Lock the Timer */ - DPRINT("Timer Referencced: %x\n", Timer); + DPRINT("Timer Referencced: 0x%p\n", Timer); KeAcquireSpinLock(&Timer->Lock, &OldIrql); /* Cancel Running Timer */ @@ -642,7 +642,7 @@ * Get the Thread. */ TimerThread = CONTAINING_RECORD(Timer->TimerApc.Thread, ETHREAD, Tcb); - DPRINT("Thread already running. Removing from Thread: %x\n", TimerThread); + DPRINT("Thread already running. Removing from Thread: 0x%p\n", TimerThread); /* Lock its active list */ KeAcquireSpinLockAtDpcLevel(&TimerThread->ActiveTimerListLock); @@ -690,7 +690,7 @@ if (TimerApcRoutine) { /* Initialize the APC */ - DPRINT("Initializing APC: %x\n", Timer->TimerApc); + DPRINT("Initializing APC: 0x%p\n", Timer->TimerApc); KeInitializeApc(&Timer->TimerApc, &CurrentThread->Tcb, CurrentApcEnvironment, _____ Modified: trunk/reactos/ntoskrnl/fs/filelock.c --- trunk/reactos/ntoskrnl/fs/filelock.c 2005-07-04 21:54:36 UTC (rev 16415) +++ trunk/reactos/ntoskrnl/fs/filelock.c 2005-07-04 22:11:00 UTC (rev 16416) @@ -798,7 +798,7 @@ { Granted = CONTAINING_RECORD(EnumEntry, FILE_LOCK_GRANTED , ListEntry); - DPRINT1("%s, start: %i, len: %i, end: %i, key: %i, proc: 0x%X, fob: 0x%X\n", + DPRINT1("%s, start: %I64x, len: %I64x, end: %I64x, key: %i, proc: 0x%p, fob: 0x%p\n", Granted->Lock.ExclusiveLock ? "EXCL" : "SHRD", Granted->Lock.StartingByte.QuadPart, Granted->Lock.Length.QuadPart, @@ -817,7 +817,7 @@ Irp = CONTAINING_RECORD(EnumEntry, IRP , Tail.Overlay.ListEntry); Stack = IoGetCurrentIrpStackLocation(Irp); - DPRINT1("%s, start: %i, len: %i, end: %i, key: %i, proc: 0x%X, fob: 0x%X\n", + DPRINT1("%s, start: %I64x, len: %I64x, end: %I64x, key: %i, proc: 0x%p, fob: 0x%p\n", (Stack->Flags & SL_EXCLUSIVE_LOCK) ? "EXCL" : "SHRD", Stack->Parameters.LockControl.ByteOffset.QuadPart, Stack->Parameters.LockControl.Length->QuadPart, _____ Modified: trunk/reactos/ntoskrnl/io/device.c --- trunk/reactos/ntoskrnl/io/device.c 2005-07-04 21:54:36 UTC (rev 16415) +++ trunk/reactos/ntoskrnl/io/device.c 2005-07-04 22:11:00 UTC (rev 16416) @@ -290,7 +290,7 @@ PDEVICE_OBJECT AttachedDevice; NTSTATUS Status = STATUS_SUCCESS; - DPRINT("IoAttachDeviceByPointer(SourceDevice %x, TargetDevice %x)\n", + DPRINT("IoAttachDeviceByPointer(SourceDevice 0x%p, TargetDevice 0x%p)\n", SourceDevice, TargetDevice); /* Do the Attach */ @@ -322,7 +322,7 @@ &LocalAttach); /* Return it */ - DPRINT("IoAttachDeviceToDeviceStack DONE: %x\n", LocalAttach); + DPRINT("IoAttachDeviceToDeviceStack DONE: 0x%p\n", LocalAttach); return LocalAttach; } @@ -338,7 +338,7 @@ PDEVICE_OBJECT AttachedDevice; PDEVOBJ_EXTENSION SourceDeviceExtension; - DPRINT("IoAttachDeviceToDeviceStack(SourceDevice %x, TargetDevice %x)\n", + DPRINT("IoAttachDeviceToDeviceStack(SourceDevice 0x%p, TargetDevice 0x%p)\n", SourceDevice, TargetDevice); /* Get the Attached Device and source extension */ @@ -425,7 +425,7 @@ HANDLE TempHandle; ASSERT_IRQL(PASSIVE_LEVEL); - DPRINT("IoCreateDevice(DriverObject %x)\n",DriverObject); + DPRINT("IoCreateDevice(DriverObject 0x%p)\n", DriverObject); /* Generate a name if we have to */ if (DeviceCharacteristics & FILE_AUTOGENERATED_DEVICE_NAME) @@ -477,7 +477,7 @@ /* Clear the whole Object and extension so we don't null stuff manually */ RtlZeroMemory(CreatedDeviceObject, TotalSize); - DPRINT("CreatedDeviceObject %x\n", CreatedDeviceObject); + DPRINT("CreatedDeviceObject 0x%p\n", CreatedDeviceObject); /* * Setup the Type and Size. Note that we don't use the aligned size, @@ -492,7 +492,7 @@ AlignedDeviceExtensionSize); /* Set the Type and Size. Question: why is Size 0 on Windows? */ - DPRINT("DeviceObjectExtension %x\n", DeviceObjectExtension); + DPRINT("DeviceObjectExtension 0x%p\n", DeviceObjectExtension); DeviceObjectExtension->Type = IO_TYPE_DEVICE_OBJECT_EXTENSION; DeviceObjectExtension->Size = 0; @@ -632,7 +632,7 @@ STDCALL IoDetachDevice(PDEVICE_OBJECT TargetDevice) { - DPRINT("IoDetachDevice(TargetDevice %x)\n", TargetDevice); + DPRINT("IoDetachDevice(TargetDevice 0x%p)\n", TargetDevice); /* Remove the attachment */ TargetDevice->AttachedDevice->DeviceObjectExtension->AttachedTo = NULL; @@ -942,7 +942,7 @@ IRP, Tail.Overlay.DeviceQueueEntry); DeviceObject->CurrentIrp = Irp; - DPRINT("Next irp is %x\n", Irp); + DPRINT("Next irp is 0x%p\n", Irp); DeviceObject->DriverObject->DriverStartIo(DeviceObject, Irp); } else @@ -969,8 +969,8 @@ PKDEVICE_QUEUE_ENTRY entry; PIRP Irp; [truncated at 1000 lines; 1060 more skipped]
19 years, 6 months
1
0
0
0
[gdalsnes] 16415: hopefully fix something in CreateClassKey
by gdalsnes@svn.reactos.com
hopefully fix something in CreateClassKey Modified: trunk/reactos/lib/setupapi/devinst.c _____ Modified: trunk/reactos/lib/setupapi/devinst.c --- trunk/reactos/lib/setupapi/devinst.c 2005-07-04 21:46:20 UTC (rev 16414) +++ trunk/reactos/lib/setupapi/devinst.c 2005-07-04 21:54:36 UTC (rev 16415) @@ -20,7 +20,7 @@ #include "config.h" #include "wine/port.h" - + #include <stdarg.h> #include "windef.h" @@ -1302,30 +1302,26 @@ MAX_PATH - 1, &RequiredSize)) { - return INVALID_HANDLE_VALUE; + return INVALID_HANDLE_VALUE; } lstrcpyW(FullBuffer, ControlClass); lstrcatW(FullBuffer, Buffer); - if (RegOpenKeyExW(HKEY_LOCAL_MACHINE, - FullBuffer, - 0, - KEY_ALL_ACCESS, - &hClassKey)) - { - if (!SetupGetLineTextW(NULL, + + if (!SetupGetLineTextW(NULL, hInf, Version, Class, Buffer, MAX_PATH, &RequiredSize)) - { - return INVALID_HANDLE_VALUE; - } + { + RegDeleteKeyW(HKEY_LOCAL_MACHINE, FullBuffer); + return INVALID_HANDLE_VALUE; + } - if (RegCreateKeyExW(HKEY_LOCAL_MACHINE, + if (ERROR_SUCCESS != RegCreateKeyExW(HKEY_LOCAL_MACHINE, FullBuffer, 0, NULL, @@ -1333,24 +1329,22 @@ KEY_ALL_ACCESS, NULL, &hClassKey, - NULL)) - { - return INVALID_HANDLE_VALUE; - } - + NULL)) + { + RegDeleteKeyW(HKEY_LOCAL_MACHINE, FullBuffer); + return INVALID_HANDLE_VALUE; } - if (RegSetValueExW(hClassKey, + if (ERROR_SUCCESS != RegSetValueExW(hClassKey, Class, 0, REG_SZ, (LPBYTE)Buffer, - RequiredSize * sizeof(WCHAR))) + RequiredSize * sizeof(WCHAR))) { - RegCloseKey(hClassKey); - RegDeleteKeyW(HKEY_LOCAL_MACHINE, - FullBuffer); - return INVALID_HANDLE_VALUE; + RegCloseKey(hClassKey); + RegDeleteKeyW(HKEY_LOCAL_MACHINE, FullBuffer); + return INVALID_HANDLE_VALUE; } return hClassKey; @@ -1397,6 +1391,7 @@ SetupCloseInfFile(hInf); return FALSE; } + RegCloseKey(hClassKey); /* Try to append a layout file */
19 years, 6 months
1
0
0
0
[navaraf] 16414: Yet another DPRINT fix.
by navaraf@svn.reactos.com
Yet another DPRINT fix. Modified: trunk/reactos/ntoskrnl/ke/i386/irq.c _____ Modified: trunk/reactos/ntoskrnl/ke/i386/irq.c --- trunk/reactos/ntoskrnl/ke/i386/irq.c 2005-07-04 21:12:35 UTC (rev 16413) +++ trunk/reactos/ntoskrnl/ke/i386/irq.c 2005-07-04 21:46:20 UTC (rev 16414) @@ -473,7 +473,7 @@ if (Result) { InsertTailList(&CurrentIsr->ListHead,&InterruptObject->InterruptListEntr y); - DPRINT("%x %x\n",InterruptObject->InterruptListEntry.Flink, InterruptObject->Entry.Blink); + DPRINT("%x %x\n",InterruptObject->InterruptListEntry.Flink, InterruptObject->InterruptListEntry.Blink); } InterruptObject->Connected = TRUE;
19 years, 6 months
1
0
0
0
[navaraf] 16413: Fix more DPRINTs.
by navaraf@svn.reactos.com
Fix more DPRINTs. Modified: trunk/reactos/ntoskrnl/ob/handle.c Modified: trunk/reactos/ntoskrnl/ob/object.c _____ Modified: trunk/reactos/ntoskrnl/ob/handle.c --- trunk/reactos/ntoskrnl/ob/handle.c 2005-07-04 21:08:00 UTC (rev 16412) +++ trunk/reactos/ntoskrnl/ob/handle.c 2005-07-04 21:12:35 UTC (rev 16413) @@ -833,7 +833,7 @@ if (ObjectType != NULL && ObjectType != ObjectHeader->Type) { - DPRINT("ObjectType mismatch: %wZ vs %wZ (handle 0x%x)\n", &ObjectType->TypeName, ObjectHeader->Type ? &ObjectHeader->Type->TypeName : NULL, Handle); + DPRINT("ObjectType mismatch: %wZ vs %wZ (handle 0x%x)\n", &ObjectType->Name, ObjectHeader->Type ? &ObjectHeader->Type->Name : NULL, Handle); ExUnlockHandleTableEntry(HandleTable, HandleEntry); @@ -1142,7 +1142,7 @@ ObjectCreateInfo->Attributes & OBJ_INHERIT, Handle); DPRINT("handle Created: %d. refcount. handlecount %d %d\n", - *Handle, Header->RefCount, Header->HandleCount); + *Handle, Header->PointerCount, Header->HandleCount); } /* We can delete the Create Info now */ _____ Modified: trunk/reactos/ntoskrnl/ob/object.c --- trunk/reactos/ntoskrnl/ob/object.c 2005-07-04 21:08:00 UTC (rev 16412) +++ trunk/reactos/ntoskrnl/ob/object.c 2005-07-04 21:12:35 UTC (rev 16413) @@ -863,9 +863,9 @@ DPRINT("Failed %p (type was %x %wZ) should be %x %wZ\n", Header, Header->Type, - &BODY_TO_HEADER(Header->Type)->NameInfo, + &HEADER_TO_OBJECT_NAME(BODY_TO_HEADER(Header->Type))->Name, ObjectType, - &BODY_TO_HEADER(ObjectType)->NameInfo); + &HEADER_TO_OBJECT_NAME(BODY_TO_HEADER(ObjectType))->Name); return(STATUS_UNSUCCESSFUL); } if (Header->Type == PsProcessType)
19 years, 6 months
1
0
0
0
[hpoussin] 16412: Remove entries that are created by 2nd stage setup, using media/inf/NET_NIC.inf
by hpoussin@svn.reactos.com
Remove entries that are created by 2nd stage setup, using media/inf/NET_NIC.inf Fix some obvious wrong copy/pastes Add correct registry entries for kbdclass and mouclass classes Fix hard-coded values for serial mice (Serenum doesn't report the exact hardwa Modified: trunk/reactos/bootdata/hivesys.inf _____ Modified: trunk/reactos/bootdata/hivesys.inf --- trunk/reactos/bootdata/hivesys.inf 2005-07-04 21:01:46 UTC (rev 16411) +++ trunk/reactos/bootdata/hivesys.inf 2005-07-04 21:08:00 UTC (rev 16412) @@ -11,16 +11,10 @@ HKLM,"SYSTEM\CurrentControlSet\Control\Class\{4D36E965-E325-11CE-BFC1-08 002BE10318}",,0x00000000,"DVD/CD-ROM drives" HKLM,"SYSTEM\CurrentControlSet\Control\Class\{4D36E965-E325-11CE-BFC1-08 002BE10318}","Class",0x00000000,"CDROM" -HKLM,"SYSTEM\CurrentControlSet\Control\Class\{4D36E972-E325-11CE-BFC1-0 8002BE10318}","EnumPropPages32",0x00000000,"MmSys.Cpl,MediaPropPageProvi der" +HKLM,"SYSTEM\CurrentControlSet\Control\Class\{4D36E965-E325-11CE-BFC1-0 8002BE10318}","EnumPropPages32",0x00000000,"MmSys.Cpl,MediaPropPageProvi der" HKLM,"SYSTEM\CurrentControlSet\Control\Class\{4D36E965-E325-11CE-BFC1-08 002BE10318}","Icon",0x00000000,"-20" HKLM,"SYSTEM\CurrentControlSet\Control\Class\{4D36E965-E325-11CE-BFC1-08 002BE10318}","NoInstallClass",0x00000000,"1" -HKLM,"SYSTEM\CurrentControlSet\Control\Class\{4D36E972-E325-11CE-BFC1-0 8002BE10318}",,0x00000000,"Network Adapters" -HKLM,"SYSTEM\CurrentControlSet\Control\Class\{4D36E972-E325-11CE-BFC1-0 8002BE10318}","Class",0x00000000,"Net" -HKLM,"SYSTEM\CurrentControlSet\Control\Class\{4D36E972-E325-11CE-BFC1-0 8002BE10318}","EnumPropPages32",0x00000000,"NetCfgx.dll,NetPropPageProvi der" -HKLM,"SYSTEM\CurrentControlSet\Control\Class\{4D36E972-E325-11CE-BFC1-0 8002BE10318}","Icon",0x00000000,"-5" -HKLM,"SYSTEM\CurrentControlSet\Control\Class\{4D36E972-E325-11CE-BFC1-0 8002BE10318}","Installer32",0x00000000,"NetCfgx.dll,NetClassInstaller" - HKLM,"SYSTEM\CurrentControlSet\Control\Class\{4D36E973-E325-11CE-BFC1-08 002BE10318}",,0x00000000,"Network Client" HKLM,"SYSTEM\CurrentControlSet\Control\Class\{4D36E973-E325-11CE-BFC1-08 002BE10318}","Class",0x00000000,"NetClient" HKLM,"SYSTEM\CurrentControlSet\Control\Class\{4D36E973-E325-11CE-BFC1-08 002BE10318}","Icon",0x00000000,"-7" @@ -80,7 +74,7 @@ HKLM,"SYSTEM\CurrentControlSet\Control\Network\{4D36E972-E325-11CE-BFC1- 08002BE10318}",,0x00000000,"Network Adapters" HKLM,"SYSTEM\CurrentControlSet\Control\Network\{4D36E972-E325-11CE-BFC1- 08002BE10318}","Class",0x00000000,"Net" HKLM,"SYSTEM\CurrentControlSet\Control\Network\{4D36E973-E325-11CE-BFC1- 08002BE10318}",,0x00000000,"Network Client" -HKLM,"SYSTEM\CurrentControlSet\Control\Network\{4D36E973-E325-11CE-BFC1 -08002BE10318}","Class",0x00000000,"Net" +HKLM,"SYSTEM\CurrentControlSet\Control\Network\{4D36E973-E325-11CE-BFC1 -08002BE10318}","Class",0x00000000,"NetClient" HKLM,"SYSTEM\CurrentControlSet\Control\Network\{4D36E974-E325-11CE-BFC1- 08002BE10318}",,0x00000000,"Network Service" HKLM,"SYSTEM\CurrentControlSet\Control\Network\{4D36E974-E325-11CE-BFC1- 08002BE10318}","Class",0x00000000,"NetService" HKLM,"SYSTEM\CurrentControlSet\Control\Network\{4D36E975-E325-11CE-BFC1- 08002BE10318}",,0x00000000,"Network Protocol" @@ -594,6 +588,7 @@ HKLM,"SYSTEM\CurrentControlSet\Services\kbdclass","ImagePath",0x00020000 ,"system32\drivers\kbdclass.sys" HKLM,"SYSTEM\CurrentControlSet\Services\kbdclass","Start",0x00010001,0x0 0000001 HKLM,"SYSTEM\CurrentControlSet\Services\kbdclass","Type",0x00010001,0x00 000001 +HKLM,"SYSTEM\CurrentControlSet\Control\Class\{4D36E96B-E325-11CE-BFC1-0 8002BE10318}","UpperFilters",0x00010000,"kbdclass" ; Serial port enumerator HKLM,"SYSTEM\CurrentControlSet\Services\serenum","ErrorControl",0x000100 01,0x00000001 @@ -651,12 +646,16 @@ HKLM,"SYSTEM\CurrentControlSet\Services\mpu401","ErrorControl",0x0001000 1,0x00000001 HKLM,"SYSTEM\CurrentControlSet\Services\mpu401","ImagePath",0x00020000," system32\drivers\mpu401.sys" -; Mouse driver -HKLM,"SYSTEM\CurrentControlSet\Services\Mouse","ErrorControl",0x0001000 1,0x00000000 -HKLM,"SYSTEM\CurrentControlSet\Services\Mouse","Group",0x00000000,"Poin ter Class" -HKLM,"SYSTEM\CurrentControlSet\Services\Mouse","ImagePath",0x00020000," system32\drivers\mouclass.sys" -HKLM,"SYSTEM\CurrentControlSet\Services\Mouse","Start",0x00010001,0x000 00001 -HKLM,"SYSTEM\CurrentControlSet\Services\Mouse","Type",0x00010001,0x0000 0001 +; Mouse class driver +HKLM,"SYSTEM\CurrentControlSet\Services\mouclass","ErrorControl",0x0001 0001,0x00000000 +HKLM,"SYSTEM\CurrentControlSet\Services\mouclass","Group",0x00000000,"P ointer Class" +HKLM,"SYSTEM\CurrentControlSet\Services\mouclass","ImagePath",0x0002000 0,"system32\drivers\mouclass.sys" +HKLM,"SYSTEM\CurrentControlSet\Services\mouclass","Start",0x00010001,0x 00000001 +HKLM,"SYSTEM\CurrentControlSet\Services\mouclass","Type",0x00010001,0x0 0000001 +HKLM,"SYSTEM\CurrentControlSet\Services\mouclass\Parameters","ConnectMu ltiplePorts",0x00010001,0x00000000 +HKLM,"SYSTEM\CurrentControlSet\Services\mouclass\Parameters","MouseData QueueSize",0x00010001,0x00000064 +HKLM,"SYSTEM\CurrentControlSet\Services\mouclass\Parameters","PointerDe viceBaseName",0x00000000,"PointerClass" +HKLM,"SYSTEM\CurrentControlSet\Control\Class\{4D36E96F-E325-11CE-BFC1-0 8002BE10318}","UpperFilters",0x00010000,"mouclass" ; Mailslot filesystem driver HKLM,"SYSTEM\CurrentControlSet\Services\Msfs","ErrorControl",0x00010001, 0x00000000 @@ -883,12 +882,8 @@ HKLM,"SYSTEM\CurrentControlSet\Services\Sermouse","Start",0x00010001,0x0 0000003 HKLM,"SYSTEM\CurrentControlSet\Services\Sermouse","Type",0x00010001,0x00 000001 ;hard coded values for some serial mice -HKLM,"SYSTEM\CurrentControlSet\Enum\*PNP0F01","Service",0x0000000,"serm ouse" -HKLM,"SYSTEM\CurrentControlSet\Enum\*PNP0F01","ClassGUID",0x0000000,"{4 D36E96F-E325-11CE-BFC1-08002BE10318}" -HKLM,"SYSTEM\CurrentControlSet\Enum\*PNP0F08","Service",0x0000000,"serm ouse" -HKLM,"SYSTEM\CurrentControlSet\Enum\*PNP0F08","ClassGUID",0x0000000,"{4 D36E96F-E325-11CE-BFC1-08002BE10318}" -HKLM,"SYSTEM\CurrentControlSet\Enum\*PNP0F09","Service",0x0000000,"serm ouse" -HKLM,"SYSTEM\CurrentControlSet\Enum\*PNP0F09","ClassGUID",0x0000000,"{4 D36E96F-E325-11CE-BFC1-08002BE10318}" +HKLM,"SYSTEM\CurrentControlSet\Enum\Serenum\Mouse\0000","Service",0x000 0000,"sermouse" +HKLM,"SYSTEM\CurrentControlSet\Enum\Serenum\Mouse\0000","ClassGUID",0x0 000000,"{4D36E96F-E325-11CE-BFC1-08002BE10318}" ; TCP/IP driver HKLM,"SYSTEM\CurrentControlSet\Services\Tcpip","ErrorControl",0x00010001 ,0x00000001
19 years, 6 months
1
0
0
0
← Newer
1
...
48
49
50
51
52
53
54
...
57
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
54
55
56
57
Results per page:
10
25
50
100
200