ReactOS.org
Sign In
Sign Up
Sign In
Sign Up
Manage this list
×
Keyboard Shortcuts
Thread View
j
: Next unread message
k
: Previous unread message
j a
: Jump to all threads
j l
: Jump to MailingList overview
2024
December
November
October
September
August
July
June
May
April
March
February
January
2023
December
November
October
September
August
July
June
May
April
March
February
January
2022
December
November
October
September
August
July
June
May
April
March
February
January
2021
December
November
October
September
August
July
June
May
April
March
February
January
2020
December
November
October
September
August
July
June
May
April
March
February
January
2019
December
November
October
September
August
July
June
May
April
March
February
January
2018
December
November
October
September
August
July
June
May
April
March
February
January
2017
December
November
October
September
August
July
June
May
April
March
February
January
2016
December
November
October
September
August
July
June
May
April
March
February
January
2015
December
November
October
September
August
July
June
May
April
March
February
January
2014
December
November
October
September
August
July
June
May
April
March
February
January
2013
December
November
October
September
August
July
June
May
April
March
February
January
2012
December
November
October
September
August
July
June
May
April
March
February
January
2011
December
November
October
September
August
July
June
May
April
March
February
January
2010
December
November
October
September
August
July
June
May
April
March
February
January
2009
December
November
October
September
August
July
June
May
April
March
February
January
2008
December
November
October
September
August
July
June
May
April
March
February
January
2007
December
November
October
September
August
July
June
May
April
March
February
January
2006
December
November
October
September
August
July
June
May
April
March
February
January
2005
December
November
October
September
August
July
June
May
April
March
February
January
2004
December
November
October
September
August
July
June
May
April
March
February
List overview
Download
Ros-diffs
July 2008
----- 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
25 participants
761 discussions
Start a n
N
ew thread
[cwittich] 34439: don't deref NULL pointer
by cwittich@svn.reactos.org
Author: cwittich Date: Sat Jul 12 08:47:06 2008 New Revision: 34439 URL:
http://svn.reactos.org/svn/reactos?rev=34439&view=rev
Log: don't deref NULL pointer Modified: trunk/reactos/subsystems/win32/win32k/ntuser/window.c Modified: trunk/reactos/subsystems/win32/win32k/ntuser/window.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/nt…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/ntuser/window.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/ntuser/window.c [iso-8859-1] Sat Jul 12 08:47:06 2008 @@ -1149,7 +1149,8 @@ WndParent->FirstChild = Wnd->NextSibling; Wnd->PrevSibling = Wnd->NextSibling = Wnd->Parent = NULL; - Wnd->Wnd->Parent = NULL; + if (Wnd->Wnd) + Wnd->Wnd->Parent = NULL; } BOOL FASTCALL
16 years, 5 months
1
0
0
0
[jimtabor] 34438: Fix FF again. Sorry, I need to research this more.
by jimtabor@svn.reactos.org
Author: jimtabor Date: Sat Jul 12 07:04:03 2008 New Revision: 34438 URL:
http://svn.reactos.org/svn/reactos?rev=34438&view=rev
Log: Fix FF again. Sorry, I need to research this more. Modified: trunk/reactos/dll/win32/user32/windows/message.c Modified: trunk/reactos/dll/win32/user32/windows/message.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/user32/windows/m…
============================================================================== --- trunk/reactos/dll/win32/user32/windows/message.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/user32/windows/message.c [iso-8859-1] Sat Jul 12 07:04:03 2008 @@ -2312,7 +2312,7 @@ BOOL WINAPI IsInsideMessagePumpHook() { - PCLIENTTHREADINFO pcti = SharedPtrToUser(((PW32CLIENTINFO)GetWin32ClientInfo())->pClientThreadInfo); + PCLIENTTHREADINFO pcti = ((PW32CLIENTINFO)GetWin32ClientInfo())->pClientThreadInfo; return (gfMessagePumpHook && pcti && (pcti->dwcPumpHook > 0)); }
16 years, 5 months
1
0
0
0
[cwittich] 34437: don't return success in getaddrinfo fixes a crash in divx installer
by cwittich@svn.reactos.org
Author: cwittich Date: Sat Jul 12 05:49:13 2008 New Revision: 34437 URL:
http://svn.reactos.org/svn/reactos?rev=34437&view=rev
Log: don't return success in getaddrinfo fixes a crash in divx installer Modified: trunk/reactos/dll/win32/ws2_32/misc/stubs.c Modified: trunk/reactos/dll/win32/ws2_32/misc/stubs.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/ws2_32/misc/stub…
============================================================================== --- trunk/reactos/dll/win32/ws2_32/misc/stubs.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/ws2_32/misc/stubs.c [iso-8859-1] Sat Jul 12 05:49:13 2008 @@ -847,7 +847,7 @@ { UNIMPLEMENTED - return 0; + return EAI_NONAME; } /*
16 years, 5 months
1
0
0
0
[pschweitzer] 34436: - Switched more files to PSEH use - Also fixed some warnings
by pschweitzer@svn.reactos.org
Author: pschweitzer Date: Sat Jul 12 04:56:52 2008 New Revision: 34436 URL:
http://svn.reactos.org/svn/reactos?rev=34436&view=rev
Log: - Switched more files to PSEH use - Also fixed some warnings Modified: branches/pierre-fsd/drivers/filesystems/ext3fsd/block.c branches/pierre-fsd/drivers/filesystems/ext3fsd/cleanup.c branches/pierre-fsd/drivers/filesystems/ext3fsd/close.c branches/pierre-fsd/drivers/filesystems/ext3fsd/debug.c Modified: branches/pierre-fsd/drivers/filesystems/ext3fsd/block.c URL:
http://svn.reactos.org/svn/reactos/branches/pierre-fsd/drivers/filesystems/…
============================================================================== --- branches/pierre-fsd/drivers/filesystems/ext3fsd/block.c [iso-8859-1] (original) +++ branches/pierre-fsd/drivers/filesystems/ext3fsd/block.c [iso-8859-1] Sat Jul 12 04:56:52 2008 @@ -4,9 +4,9 @@ * FILE: block.c * PROGRAMMER: Matt Wu <mattwu(a)163.com> * HOMEPAGE:
http://ext2.yeah.net
- * UPDATE HISTORY: 11 Jul 2008 - * Replaced SEH support with PSEH support (Pierre Schweitzer <heis_spiter(a)hotmail.com>) - * Fixed some warning under GCC + * UPDATE HISTORY: 11 Jul 2008 (Pierre Schweitzer <heis_spiter(a)hotmail.com>) + * Replaced SEH support with PSEH support + * Fixed some warnings under GCC */ /* INCLUDES *****************************************************************/ Modified: branches/pierre-fsd/drivers/filesystems/ext3fsd/cleanup.c URL:
http://svn.reactos.org/svn/reactos/branches/pierre-fsd/drivers/filesystems/…
============================================================================== --- branches/pierre-fsd/drivers/filesystems/ext3fsd/cleanup.c [iso-8859-1] (original) +++ branches/pierre-fsd/drivers/filesystems/ext3fsd/cleanup.c [iso-8859-1] Sat Jul 12 04:56:52 2008 @@ -4,7 +4,8 @@ * FILE: cleanup.c * PROGRAMMER: Matt Wu <mattwu(a)163.com> * HOMEPAGE:
http://ext2.yeah.net
- * UPDATE HISTORY: + * UPDATE HISTORY: 12 Jul 2008 (Pierre Schweitzer <heis_spiter(a)hotmail.com>) + * Replaced SEH support with PSEH support */ /* INCLUDES *****************************************************************/ @@ -16,11 +17,77 @@ extern PEXT2_GLOBAL Ext2Global; /* DEFINITIONS *************************************************************/ + +VOID +Ext2CleanupFinal ( + IN PEXT2_IRP_CONTEXT IrpContext, + IN PNTSTATUS pStatus, + IN PEXT2_VCB Vcb, + IN PEXT2_FCB Fcb, + IN BOOLEAN VcbResourceAcquired, + IN BOOLEAN FcbResourceAcquired, + IN BOOLEAN FcbPagingIoResourceAcquired ); #ifdef ALLOC_PRAGMA #pragma alloc_text(PAGE, Ext2Cleanup) #endif + +/* FUNCTIONS ***************************************************************/ + + +_SEH_DEFINE_LOCALS(Ext2CleanupFinal) +{ + PEXT2_IRP_CONTEXT IrpContext; + PNTSTATUS pStatus; + PEXT2_VCB Vcb; + PEXT2_FCB Fcb; + BOOLEAN VcbResourceAcquired; + BOOLEAN FcbResourceAcquired; + BOOLEAN FcbPagingIoResourceAcquired; +}; + +_SEH_FINALLYFUNC(Ext2CleanupFinal_PSEH) +{ + _SEH_ACCESS_LOCALS(Ext2CleanupFinal); + Ext2CleanupFinal(_SEH_VAR(IrpContext), _SEH_VAR(pStatus), _SEH_VAR(Vcb), + _SEH_VAR(Fcb), _SEH_VAR(VcbResourceAcquired), + _SEH_VAR(FcbResourceAcquired), + _SEH_VAR(FcbPagingIoResourceAcquired)); +} + +VOID +Ext2CleanupFinal ( + IN PEXT2_IRP_CONTEXT IrpContext, + IN PNTSTATUS pStatus, + IN PEXT2_VCB Vcb, + IN PEXT2_FCB Fcb, + IN BOOLEAN VcbResourceAcquired, + IN BOOLEAN FcbResourceAcquired, + IN BOOLEAN FcbPagingIoResourceAcquired + ) +{ + if (FcbPagingIoResourceAcquired) { + ExReleaseResourceLite(&Fcb->PagingIoResource); + } + + if (FcbResourceAcquired) { + ExReleaseResourceLite(&Fcb->MainResource); + } + + if (VcbResourceAcquired) { + ExReleaseResourceLite(&Vcb->MainResource); + } + + if (!IrpContext->ExceptionInProgress) { + if (*pStatus == STATUS_PENDING) { + Ext2QueueRequest(IrpContext); + } else { + IrpContext->Irp->IoStatus.Status = *pStatus; + Ext2CompleteIrpContext(IrpContext, *pStatus); + } + } +} NTSTATUS Ext2Cleanup (IN PEXT2_IRP_CONTEXT IrpContext) @@ -33,11 +100,14 @@ PEXT2_CCB Ccb; PIRP Irp; - BOOLEAN VcbResourceAcquired = FALSE; - BOOLEAN FcbResourceAcquired = FALSE; - BOOLEAN FcbPagingIoResourceAcquired = FALSE; - - __try { + _SEH_TRY { + + _SEH_DECLARE_LOCALS(Ext2CleanupFinal); + _SEH_VAR(IrpContext) = IrpContext; + _SEH_VAR(pStatus) = &Status; + _SEH_VAR(VcbResourceAcquired) = FALSE; + _SEH_VAR(FcbResourceAcquired) = FALSE; + _SEH_VAR(FcbPagingIoResourceAcquired) = FALSE; ASSERT(IrpContext != NULL); ASSERT((IrpContext->Identifier.Type == EXT2ICX) && @@ -46,34 +116,36 @@ DeviceObject = IrpContext->DeviceObject; if (IsExt2FsDevice(DeviceObject)) { Status = STATUS_SUCCESS; - __leave; + _SEH_LEAVE; } Irp = IrpContext->Irp; Vcb = (PEXT2_VCB) DeviceObject->DeviceExtension; + _SEH_VAR(Vcb) = Vcb; ASSERT(Vcb != NULL); ASSERT((Vcb->Identifier.Type == EXT2VCB) && (Vcb->Identifier.Size == sizeof(EXT2_VCB))); if (!IsFlagOn(Vcb->Flags, VCB_INITIALIZED)) { Status = STATUS_SUCCESS; - __leave; + _SEH_LEAVE; } FileObject = IrpContext->FileObject; Fcb = (PEXT2_FCB) FileObject->FsContext; + _SEH_VAR(Fcb) = Fcb; if (!Fcb || (Fcb->Identifier.Type != EXT2VCB && Fcb->Identifier.Type != EXT2FCB)) { Status = STATUS_SUCCESS; - __leave; + _SEH_LEAVE; } if (IsFlagOn(FileObject->Flags, FO_CLEANUP_COMPLETE)) { Status = STATUS_SUCCESS; - __leave; - } - - VcbResourceAcquired = + _SEH_LEAVE; + } + + _SEH_VAR(VcbResourceAcquired) = ExAcquireResourceExclusiveLite( &Vcb->MainResource, IsFlagOn(IrpContext->Flags, IRP_CONTEXT_FLAG_WAIT) @@ -96,7 +168,7 @@ } Status = STATUS_SUCCESS; - __leave; + _SEH_LEAVE; } ASSERT((Fcb->Identifier.Type == EXT2FCB) && @@ -110,12 +182,12 @@ !IsFlagOn(Vcb->Flags, VCB_WRITE_PROTECTED) ) { Status = Ext2FlushFile(IrpContext, Fcb, Ccb); } - __leave; + _SEH_LEAVE; } if (Ccb == NULL) { Status = STATUS_SUCCESS; - __leave; + _SEH_LEAVE; } if (IsDirectory(Fcb)) { @@ -140,9 +212,9 @@ } ExReleaseResourceLite(&Vcb->MainResource); - VcbResourceAcquired = FALSE; - - FcbResourceAcquired = + _SEH_VAR(VcbResourceAcquired) = FALSE; + + _SEH_VAR(FcbResourceAcquired) = ExAcquireResourceExclusiveLite( &Fcb->MainResource, IsFlagOn(IrpContext->Flags, IRP_CONTEXT_FLAG_WAIT) @@ -235,7 +307,7 @@ LARGE_INTEGER Size; ExAcquireResourceExclusiveLite(&Fcb->PagingIoResource, TRUE); - FcbPagingIoResourceAcquired = TRUE; + _SEH_VAR(FcbPagingIoResourceAcquired) = TRUE; Size.QuadPart = CEILING_ALIGNED(ULONGLONG, (ULONGLONG)Fcb->Mcb->FileSize.QuadPart, @@ -258,7 +330,7 @@ ClearLongFlag(Fcb->Flags, FCB_ALLOC_IN_CREATE|FCB_ALLOC_IN_WRITE); Fcb->RealSize.QuadPart = 0; ExReleaseResourceLite(&Fcb->PagingIoResource); - FcbPagingIoResourceAcquired = FALSE; + _SEH_VAR(FcbPagingIoResourceAcquired) = FALSE; } } @@ -272,9 +344,9 @@ // Ext2DeleteFile will acquire these lock inside // - if (FcbResourceAcquired) { + if (_SEH_VAR(FcbResourceAcquired)) { ExReleaseResourceLite(&Fcb->MainResource); - FcbResourceAcquired = FALSE; + _SEH_VAR(FcbResourceAcquired) = FALSE; } // @@ -310,7 +382,7 @@ // re-acquire the main resource lock // - FcbResourceAcquired = + _SEH_VAR(FcbResourceAcquired) = ExAcquireResourceExclusiveLite( &Fcb->MainResource, IsFlagOn(IrpContext->Flags, IRP_CONTEXT_FLAG_WAIT) @@ -361,29 +433,9 @@ SetFlag(FileObject->Flags, FO_CLEANUP_COMPLETE); } - } __finally { - - if (FcbPagingIoResourceAcquired) { - ExReleaseResourceLite(&Fcb->PagingIoResource); - } - - if (FcbResourceAcquired) { - ExReleaseResourceLite(&Fcb->MainResource); - } - - if (VcbResourceAcquired) { - ExReleaseResourceLite(&Vcb->MainResource); - } - - if (!IrpContext->ExceptionInProgress) { - if (Status == STATUS_PENDING) { - Ext2QueueRequest(IrpContext); - } else { - IrpContext->Irp->IoStatus.Status = Status; - Ext2CompleteIrpContext(IrpContext, Status); - } - } } + _SEH_FINALLY(Ext2CleanupFinal_PSEH) + _SEH_END; return Status; } Modified: branches/pierre-fsd/drivers/filesystems/ext3fsd/close.c URL:
http://svn.reactos.org/svn/reactos/branches/pierre-fsd/drivers/filesystems/…
============================================================================== --- branches/pierre-fsd/drivers/filesystems/ext3fsd/close.c [iso-8859-1] (original) +++ branches/pierre-fsd/drivers/filesystems/ext3fsd/close.c [iso-8859-1] Sat Jul 12 04:56:52 2008 @@ -4,7 +4,8 @@ * FILE: close.c * PROGRAMMER: Matt Wu <mattwu(a)163.com> * HOMEPAGE:
http://ext2.yeah.net
- * UPDATE HISTORY: + * UPDATE HISTORY: 12 Jul 2008 (Pierre Schweitzer <heis_spiter(a)hotmail.com>) + * Replaced SEH support with PSEH support */ /* INCLUDES *****************************************************************/ @@ -16,6 +17,18 @@ extern PEXT2_GLOBAL Ext2Global; /* DEFINITIONS *************************************************************/ + +VOID +Ext2CloseFinal ( + IN PEXT2_IRP_CONTEXT IrpContext, + IN PNTSTATUS pStatus, + IN PEXT2_VCB Vcb, + IN BOOLEAN VcbResourceAcquired, + IN PEXT2_FCB Fcb, + IN BOOLEAN FcbResourceAcquired, + IN BOOLEAN bDeleteVcb, + IN BOOLEAN bBeingClosed, + IN BOOLEAN bSkipLeave ); #ifdef ALLOC_PRAGMA #pragma alloc_text(PAGE, Ext2Close) @@ -23,22 +36,107 @@ #pragma alloc_text(PAGE, Ext2DeQueueCloseRequest) #endif + +/* FUNCTIONS ***************************************************************/ + + +_SEH_DEFINE_LOCALS(Ext2CloseFinal) +{ + PEXT2_IRP_CONTEXT IrpContext; + PNTSTATUS pStatus; + PEXT2_VCB Vcb; + BOOLEAN VcbResourceAcquired; + PEXT2_FCB Fcb; + BOOLEAN FcbResourceAcquired; + BOOLEAN bDeleteVcb; + BOOLEAN bBeingClosed; + BOOLEAN bSkipLeave; +}; + +_SEH_FINALLYFUNC(Ext2CloseFinal_PSEH) +{ + _SEH_ACCESS_LOCALS(Ext2CloseFinal); + Ext2CloseFinal(_SEH_VAR(IrpContext), _SEH_VAR(pStatus), _SEH_VAR(Vcb), + _SEH_VAR(VcbResourceAcquired), _SEH_VAR(Fcb), + _SEH_VAR(FcbResourceAcquired), _SEH_VAR(bDeleteVcb), + _SEH_VAR(bBeingClosed), _SEH_VAR(bSkipLeave)); +} + +VOID +Ext2CloseFinal ( + IN PEXT2_IRP_CONTEXT IrpContext, + IN PNTSTATUS pStatus, + IN PEXT2_VCB Vcb, + IN BOOLEAN VcbResourceAcquired, + IN PEXT2_FCB Fcb, + IN BOOLEAN FcbResourceAcquired, + IN BOOLEAN bDeleteVcb, + IN BOOLEAN bBeingClosed, + IN BOOLEAN bSkipLeave + ) +{ + if (bSkipLeave && !bBeingClosed) { + ClearFlag(Vcb->Flags, VCB_BEING_CLOSED); + } + + if (FcbResourceAcquired) { + ExReleaseResourceLite(&Fcb->MainResource); + } + + if (VcbResourceAcquired) { + ExReleaseResourceLite(&Vcb->MainResource); + } + + if (!IrpContext->ExceptionInProgress) { + + if (*pStatus == STATUS_PENDING) { + + Ext2QueueCloseRequest(IrpContext); + + } else { + + Ext2CompleteIrpContext(IrpContext, *pStatus); + + if (bDeleteVcb) { + + PVPB Vpb = Vcb->Vpb; + DEBUG(DL_DBG, ( "Ext2Close: Try to free Vcb %p and Vpb %p\n", + Vcb, Vpb)); + + if (Ext2CheckDismount(IrpContext, Vcb, FALSE)) { + if ((Vpb->RealDevice->Vpb != Vpb) && + !IsFlagOn(Vpb->Flags, VPB_PERSISTENT)) { + DEC_MEM_COUNT(PS_VPB, Vpb, sizeof(VPB)); + DEBUG(DL_DBG, ( "Ext2Close: freeing Vpb %p\n", Vpb)); + ExFreePoolWithTag(Vpb, TAG_VPB); + } + Ext2ClearVpbFlag(Vcb->Vpb, VPB_MOUNTED); + } + } + } + } +} + NTSTATUS Ext2Close (IN PEXT2_IRP_CONTEXT IrpContext) { PDEVICE_OBJECT DeviceObject; NTSTATUS Status = STATUS_SUCCESS; PEXT2_VCB Vcb; - BOOLEAN VcbResourceAcquired = FALSE; PFILE_OBJECT FileObject; PEXT2_FCB Fcb; - BOOLEAN FcbResourceAcquired = FALSE; PEXT2_CCB Ccb; - BOOLEAN bDeleteVcb = FALSE; - BOOLEAN bBeingClosed = FALSE; - BOOLEAN bSkipLeave = FALSE; - - __try { + + _SEH_TRY { + + _SEH_DECLARE_LOCALS(Ext2CloseFinal); + _SEH_VAR(IrpContext) = IrpContext; + _SEH_VAR(pStatus) = &Status; + _SEH_VAR(VcbResourceAcquired) = FALSE; + _SEH_VAR(FcbResourceAcquired) = FALSE; + _SEH_VAR(bDeleteVcb) = FALSE; + _SEH_VAR(bBeingClosed) = FALSE; + _SEH_VAR(bSkipLeave) = FALSE; ASSERT(IrpContext != NULL); ASSERT((IrpContext->Identifier.Type == EXT2ICX) && @@ -47,10 +145,11 @@ DeviceObject = IrpContext->DeviceObject; if (IsExt2FsDevice(DeviceObject)) { Status = STATUS_SUCCESS; - __leave; + _SEH_LEAVE; } Vcb = (PEXT2_VCB) DeviceObject->DeviceExtension; + _SEH_VAR(Vcb) = Vcb; ASSERT(Vcb != NULL); ASSERT((Vcb->Identifier.Type == EXT2VCB) && (Vcb->Identifier.Size == sizeof(EXT2_VCB))); @@ -62,31 +161,33 @@ Vcb->OpenFileHandleCount, Vcb->ReferenceCount)); Status = STATUS_PENDING; - __leave; - } - VcbResourceAcquired = TRUE; - - bSkipLeave = TRUE; + _SEH_LEAVE; + } + _SEH_VAR(VcbResourceAcquired) = TRUE; + + _SEH_VAR(bSkipLeave) = TRUE; if (IsFlagOn(Vcb->Flags, VCB_BEING_CLOSED)) { - bBeingClosed = TRUE; + _SEH_VAR(bBeingClosed) = TRUE; } else { SetLongFlag(Vcb->Flags, VCB_BEING_CLOSED); - bBeingClosed = FALSE; + _SEH_VAR(bBeingClosed) = FALSE; } if (IsFlagOn(IrpContext->Flags, IRP_CONTEXT_FLAG_DELAY_CLOSE)) { FileObject = NULL; Fcb = IrpContext->Fcb; + _SEH_VAR(Fcb) = Fcb; Ccb = IrpContext->Ccb; } else { FileObject = IrpContext->FileObject; Fcb = (PEXT2_FCB) FileObject->FsContext; + _SEH_VAR(Fcb) = Fcb; if (!Fcb) { Status = STATUS_SUCCESS; - __leave; + _SEH_LEAVE; } ASSERT(Fcb != NULL); Ccb = (PEXT2_CCB) FileObject->FsContext2; @@ -94,13 +195,13 @@ DEBUG(DL_DBG, ( "Ext2Close: (VCB) bBeingClosed = %d Vcb = %p ReferCount = %d\n", - bBeingClosed, Vcb, Vcb->ReferenceCount)); + _SEH_VAR(bBeingClosed), Vcb, Vcb->ReferenceCount)); if (Fcb->Identifier.Type == EXT2VCB) { - if ((!bBeingClosed) && (Vcb->ReferenceCount <= 1)&& + if ((!_SEH_VAR(bBeingClosed)) && (Vcb->ReferenceCount <= 1)&& (!IsMounted(Vcb) || IsDispending(Vcb))) { - bDeleteVcb = TRUE; + _SEH_VAR(bDeleteVcb) = TRUE; } if (Ccb) { @@ -114,27 +215,27 @@ } Status = STATUS_SUCCESS; - __leave; + _SEH_LEAVE; } if ( Fcb->Identifier.Type != EXT2FCB || Fcb->Identifier.Size != sizeof(EXT2_FCB)) { - __leave; + _SEH_LEAVE; } if (!ExAcquireResourceExclusiveLite( &Fcb->MainResource, IsFlagOn(IrpContext->Flags, IRP_CONTEXT_FLAG_WAIT) )) { Status = STATUS_PENDING; - __leave; - } - FcbResourceAcquired = TRUE; + _SEH_LEAVE; + } + _SEH_VAR(FcbResourceAcquired) = TRUE; Fcb->Header.IsFastIoPossible = FastIoIsNotPossible; if (!Ccb) { Status = STATUS_SUCCESS; - __leave; + _SEH_LEAVE; } ASSERT((Ccb->Identifier.Type == EXT2CCB) && @@ -144,14 +245,14 @@ SetFlag(IrpContext->Flags, IRP_CONTEXT_FLAG_FILE_BUSY); DEBUG(DL_USR, ( "Ext2Close: busy bit set: %wZ\n", &Fcb->Mcb->FullName )); Status = STATUS_PENDING; - __leave; + _SEH_LEAVE; } Ext2DerefXcb(&Vcb->ReferenceCount); - if ((!bBeingClosed) && !Vcb->ReferenceCount && + if ((!_SEH_VAR(bBeingClosed)) && !Vcb->ReferenceCount && (!IsMounted(Vcb) || IsDispending(Vcb))) { - bDeleteVcb = TRUE; + _SEH_VAR(bDeleteVcb) = TRUE; DEBUG(DL_DBG, ( "Ext2Close: Vcb is being released.\n")); } @@ -173,9 +274,9 @@ // Remove Fcb from Vcb->FcbList ... // - if (FcbResourceAcquired) { + if (_SEH_VAR(FcbResourceAcquired)) { ExReleaseResourceLite(&Fcb->MainResource); - FcbResourceAcquired = FALSE; + _SEH_VAR(FcbResourceAcquired) = FALSE; } Ext2FreeFcb(Fcb); @@ -187,49 +288,9 @@ Status = STATUS_SUCCESS; - } __finally { - - if (bSkipLeave && !bBeingClosed) { - ClearFlag(Vcb->Flags, VCB_BEING_CLOSED); - } - - if (FcbResourceAcquired) { - ExReleaseResourceLite(&Fcb->MainResource); - } - - if (VcbResourceAcquired) { - ExReleaseResourceLite(&Vcb->MainResource); - } - - if (!IrpContext->ExceptionInProgress) { - - if (Status == STATUS_PENDING) { - - Ext2QueueCloseRequest(IrpContext); - - } else { - - Ext2CompleteIrpContext(IrpContext, Status); - - if (bDeleteVcb) { - - PVPB Vpb = Vcb->Vpb; - DEBUG(DL_DBG, ( "Ext2Close: Try to free Vcb %p and Vpb %p\n", - Vcb, Vpb)); - - if (Ext2CheckDismount(IrpContext, Vcb, FALSE)) { - if ((Vpb->RealDevice->Vpb != Vpb) && - !IsFlagOn(Vpb->Flags, VPB_PERSISTENT)) { - DEC_MEM_COUNT(PS_VPB, Vpb, sizeof(VPB)); - DEBUG(DL_DBG, ( "Ext2Close: freeing Vpb %p\n", Vpb)); - ExFreePoolWithTag(Vpb, TAG_VPB); - } - Ext2ClearVpbFlag(Vcb->Vpb, VPB_MOUNTED); - } - } - } - } - } + } + _SEH_FINALLY(Ext2CloseFinal_PSEH) + _SEH_END; return Status; } @@ -266,6 +327,19 @@ ExQueueWorkItem(&IrpContext->WorkQueueItem, DelayedWorkQueue); } +_SEH_DEFINE_LOCALS(Ext2ExceptionFilter) +{ + PEXT2_IRP_CONTEXT IrpContext; +}; + +_SEH_FILTER(Ext2ExceptionFilter_PSEH) +{ + _SEH_ACCESS_LOCALS(Ext2ExceptionFilter); + return Ext2ExceptionFilter(_SEH_VAR(IrpContext), _SEH_GetExceptionPointers()); +} + +_SEH_WRAP_FINALLY(FsRtlExitFileSystem_PSEH_finally, FsRtlExitFileSystem); + VOID Ext2DeQueueCloseRequest (IN PVOID Context) { @@ -276,20 +350,24 @@ ASSERT((IrpContext->Identifier.Type == EXT2ICX) && (IrpContext->Identifier.Size == sizeof(EXT2_IRP_CONTEXT))); - __try { - - __try { + _SEH_TRY { + + _SEH_DECLARE_LOCALS(Ext2ExceptionFilter); + _SEH_VAR(IrpContext) = IrpContext; + + _SEH_TRY { FsRtlEnterFileSystem(); Ext2Close(IrpContext); - } __except (Ext2ExceptionFilter(IrpContext, GetExceptionInformation())) { + } + _SEH_EXCEPT(Ext2ExceptionFilter_PSEH) { Ext2ExceptionHandler(IrpContext); } - - } __finally { - - FsRtlExitFileSystem(); - } -} + _SEH_END; + + } + _SEH_FINALLY(FsRtlExitFileSystem_PSEH_finally) + _SEH_END; +} Modified: branches/pierre-fsd/drivers/filesystems/ext3fsd/debug.c URL:
http://svn.reactos.org/svn/reactos/branches/pierre-fsd/drivers/filesystems/…
============================================================================== --- branches/pierre-fsd/drivers/filesystems/ext3fsd/debug.c [iso-8859-1] (original) +++ branches/pierre-fsd/drivers/filesystems/ext3fsd/debug.c [iso-8859-1] Sat Jul 12 04:56:52 2008 @@ -4,7 +4,8 @@ * FILE: Debug.c * PROGRAMMER: Matt Wu <mattwu(a)163.com> * HOMEPAGE:
http://ext2.yeah.net
- * UPDATE HISTORY: + * UPDATE HISTORY: 12 Jul 2008 (Pierre Schweitzer <heis_spiter(a)hotmail.com>) + * Fixed some warnings under GCC */ /* INCLUDES **************************************************************/ @@ -36,7 +37,7 @@ /* Static Definitions ****************************************************/ -static PUCHAR IrpMjStrings[] = { +static PCHAR IrpMjStrings[] = { "IRP_MJ_CREATE", "IRP_MJ_CREATE_NAMED_PIPE", "IRP_MJ_CLOSE", @@ -67,7 +68,7 @@ "IRP_MJ_PNP" }; -static PUCHAR FileInformationClassStrings[] = { +static PCHAR FileInformationClassStrings[] = { "Unknown FileInformationClass 0", "FileDirectoryInformation", "FileFullDirectoryInformation", @@ -107,7 +108,7 @@ "FileTrackingInformation" }; -static PUCHAR FsInformationClassStrings[] = { +static PCHAR FsInformationClassStrings[] = { "Unknown FsInformationClass 0", "FileFsVolumeInformation", "FileFsLabelInformation", @@ -742,7 +743,7 @@ } } -PUCHAR +PCHAR Ext2NtStatusToString ( IN NTSTATUS Status ) { switch (Status) {
16 years, 5 months
1
0
0
0
[cwittich] 34435: fix a typo
by cwittich@svn.reactos.org
Author: cwittich Date: Sat Jul 12 04:39:30 2008 New Revision: 34435 URL:
http://svn.reactos.org/svn/reactos?rev=34435&view=rev
Log: fix a typo Modified: trunk/reactos/dll/win32/ws2_32/misc/handle.c Modified: trunk/reactos/dll/win32/ws2_32/misc/handle.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/ws2_32/misc/hand…
============================================================================== --- trunk/reactos/dll/win32/ws2_32/misc/handle.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/ws2_32/misc/handle.c [iso-8859-1] Sat Jul 12 04:39:30 2008 @@ -227,7 +227,7 @@ ProviderHandle = GetProviderByHandle(ProviderHandleTable, Handle); - WS_DbgPrint(MID_TRACE, ("ProviderHanddle is %x\n", ProviderHandle)); + WS_DbgPrint(MID_TRACE, ("ProviderHandle is %x\n", ProviderHandle)); LeaveCriticalSection(&ProviderHandleTableLock);
16 years, 5 months
1
0
0
0
[pschweitzer] 34434: - Updated header with recent changes - Fixed a typo
by pschweitzer@svn.reactos.org
Author: pschweitzer Date: Sat Jul 12 03:24:27 2008 New Revision: 34434 URL:
http://svn.reactos.org/svn/reactos?rev=34434&view=rev
Log: - Updated header with recent changes - Fixed a typo Modified: branches/pierre-fsd/drivers/filesystems/ext3fsd/block.c Modified: branches/pierre-fsd/drivers/filesystems/ext3fsd/block.c URL:
http://svn.reactos.org/svn/reactos/branches/pierre-fsd/drivers/filesystems/…
============================================================================== --- branches/pierre-fsd/drivers/filesystems/ext3fsd/block.c [iso-8859-1] (original) +++ branches/pierre-fsd/drivers/filesystems/ext3fsd/block.c [iso-8859-1] Sat Jul 12 03:24:27 2008 @@ -4,7 +4,9 @@ * FILE: block.c * PROGRAMMER: Matt Wu <mattwu(a)163.com> * HOMEPAGE:
http://ext2.yeah.net
- * UPDATE HISTORY: + * UPDATE HISTORY: 11 Jul 2008 + * Replaced SEH support with PSEH support (Pierre Schweitzer <heis_spiter(a)hotmail.com>) + * Fixed some warning under GCC */ /* INCLUDES *****************************************************************/ @@ -198,7 +200,7 @@ _SEH_DEFINE_LOCALS(Ext2ReadWriteBlocksFinal) { - IN PEXT2_IRP_CONTEXT IrpContext; + PEXT2_IRP_CONTEXT IrpContext; PEXT2_EXTENT Chain; PIRP MasterIrp; PNTSTATUS pStatus;
16 years, 5 months
1
0
0
0
[jimtabor] 34433: - Fix problem with share pointer. See bug 3503. It seems to be a problem with ntdll and msvcrt.
by jimtabor@svn.reactos.org
Author: jimtabor Date: Fri Jul 11 20:00:58 2008 New Revision: 34433 URL:
http://svn.reactos.org/svn/reactos?rev=34433&view=rev
Log: - Fix problem with share pointer. See bug 3503. It seems to be a problem with ntdll and msvcrt. Modified: trunk/reactos/dll/win32/user32/windows/message.c Modified: trunk/reactos/dll/win32/user32/windows/message.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/user32/windows/m…
============================================================================== --- trunk/reactos/dll/win32/user32/windows/message.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/user32/windows/message.c [iso-8859-1] Fri Jul 11 20:00:58 2008 @@ -1081,13 +1081,13 @@ STDCALL InSendMessage(VOID) { - PCLIENTTHREADINFO pcti = ((PW32CLIENTINFO)GetWin32ClientInfo())->pClientThreadInfo; + PCLIENTTHREADINFO pcti = SharedPtrToUser(((PW32CLIENTINFO)GetWin32ClientInfo())->pClientThreadInfo); if ( pcti ) return (pcti->CTI_flags & CTI_INSENDMESSAGE); else - /* return(NtUserGetThreadState(THREADSTATE_INSENDMESSAGE) != ISMEX_NOSEND); */ return FALSE; +/* return(NtUserGetThreadState(THREADSTATE_INSENDMESSAGE) != ISMEX_NOSEND);*/ } @@ -1099,7 +1099,7 @@ InSendMessageEx( LPVOID lpReserved) { - PCLIENTTHREADINFO pcti = ((PW32CLIENTINFO)GetWin32ClientInfo())->pClientThreadInfo; + PCLIENTTHREADINFO pcti = SharedPtrToUser(((PW32CLIENTINFO)GetWin32ClientInfo())->pClientThreadInfo); if (pcti && !(pcti->CTI_flags & CTI_INSENDMESSAGE)) return ISMEX_NOSEND; else @@ -2312,7 +2312,7 @@ BOOL WINAPI IsInsideMessagePumpHook() { - PCLIENTTHREADINFO pcti = ((PW32CLIENTINFO)GetWin32ClientInfo())->pClientThreadInfo; + PCLIENTTHREADINFO pcti = SharedPtrToUser(((PW32CLIENTINFO)GetWin32ClientInfo())->pClientThreadInfo); return (gfMessagePumpHook && pcti && (pcti->dwcPumpHook > 0)); }
16 years, 5 months
1
0
0
0
[silverblade] 34432: Having changed all the code to use DPRINT and subsequently DbgPrint, it transpires that Win NT4 does not support the use of these functions in user-mode, rendering them pretty much useless to me. Reverted to spewing out macro'd printfs instead, so it shouldn't be hard to change the debug output method when these components finally make it over to ReactOS.
by silverblade@svn.reactos.org
Author: silverblade Date: Fri Jul 11 19:49:34 2008 New Revision: 34432 URL:
http://svn.reactos.org/svn/reactos?rev=34432&view=rev
Log: Having changed all the code to use DPRINT and subsequently DbgPrint, it transpires that Win NT4 does not support the use of these functions in user-mode, rendering them pretty much useless to me. Reverted to spewing out macro'd printfs instead, so it shouldn't be hard to change the debug output method when these components finally make it over to ReactOS. Modified: branches/silverblade-audio/dll/win32/mmdrv/testing.c branches/silverblade-audio/dll/win32/sndblst/sndblst.c branches/silverblade-audio/include/reactos/libs/sound/mmebuddy.h branches/silverblade-audio/lib/drivers/sound/mmebuddy/devices.c branches/silverblade-audio/lib/drivers/sound/mmebuddy/instances.c branches/silverblade-audio/lib/drivers/sound/mmebuddy/kernel.c branches/silverblade-audio/lib/drivers/sound/mmebuddy/mme/auxMessage.c branches/silverblade-audio/lib/drivers/sound/mmebuddy/mme/midMessage.c branches/silverblade-audio/lib/drivers/sound/mmebuddy/mme/modMessage.c branches/silverblade-audio/lib/drivers/sound/mmebuddy/mme/mxdMessage.c branches/silverblade-audio/lib/drivers/sound/mmebuddy/mme/widMessage.c branches/silverblade-audio/lib/drivers/sound/mmebuddy/mme/wodMessage.c branches/silverblade-audio/lib/drivers/sound/mmebuddy/nt4.c branches/silverblade-audio/lib/drivers/sound/mmebuddy/thread.c branches/silverblade-audio/lib/drivers/sound/mmebuddy/utility.c branches/silverblade-audio/lib/drivers/sound/mmebuddy/wave/wavethread.c Modified: branches/silverblade-audio/dll/win32/mmdrv/testing.c URL:
http://svn.reactos.org/svn/reactos/branches/silverblade-audio/dll/win32/mmd…
============================================================================== --- branches/silverblade-audio/dll/win32/mmdrv/testing.c [iso-8859-1] (original) +++ branches/silverblade-audio/dll/win32/mmdrv/testing.c [iso-8859-1] Fri Jul 11 19:49:34 2008 @@ -17,7 +17,6 @@ #include <mmsystem.h> #include <mmddk.h> #include <ntddsnd.h> -#include <debug.h> #include <ntddk.h> #include <mmebuddy.h> @@ -212,11 +211,11 @@ /* Report the number of wave output devices */ NumWaveOuts = wodMessage(0, WODM_GETNUMDEVS, 0, 0, 0); - DPRINT("Wave outs = %d\n", NumWaveOuts); + TRACE_("Wave outs = %d\n", (int) NumWaveOuts); if ( NumWaveOuts < 1 ) { - DPRINT("Nothing to do as no waveout devices!"); + WARN_("Nothing to do as no waveout devices!"); return; } Modified: branches/silverblade-audio/dll/win32/sndblst/sndblst.c URL:
http://svn.reactos.org/svn/reactos/branches/silverblade-audio/dll/win32/snd…
============================================================================== --- branches/silverblade-audio/dll/win32/sndblst/sndblst.c [iso-8859-1] (original) +++ branches/silverblade-audio/dll/win32/sndblst/sndblst.c [iso-8859-1] Fri Jul 11 19:49:34 2008 @@ -16,8 +16,7 @@ #include <ntddsnd.h> #include <mmddk.h> #include <mmebuddy.h> -#include <debug.h> - +//#include <debug.h> PWSTR SBWaveOutDeviceName = L"Sound Blaster Playback"; PWSTR SBWaveInDeviceName = L"Sound Blaster Recording"; @@ -90,7 +89,7 @@ switch ( message ) { case DRV_LOAD : - DPRINT("DRV_LOAD"); + TRACE_("DRV_LOAD"); EnumerateNt4ServiceSoundDevices(L"sndblst", 0, @@ -102,14 +101,14 @@ return 1L; case DRV_FREE : - DPRINT("DRV_FREE"); + TRACE_("DRV_FREE"); StopSoundThread(); RemoveAllSoundDevices(); // SOUND_DEBUG_HEX(GetMemoryAllocations()); - DPRINT("Leaving driver with %d memory allocations present\n", GetMemoryAllocations()); + TRACE_("Leaving driver with %d memory allocations present\n", (int) GetMemoryAllocations()); return 1L; Modified: branches/silverblade-audio/include/reactos/libs/sound/mmebuddy.h URL:
http://svn.reactos.org/svn/reactos/branches/silverblade-audio/include/react…
============================================================================== --- branches/silverblade-audio/include/reactos/libs/sound/mmebuddy.h [iso-8859-1] (original) +++ branches/silverblade-audio/include/reactos/libs/sound/mmebuddy.h [iso-8859-1] Fri Jul 11 19:49:34 2008 @@ -24,6 +24,45 @@ #define POPUP(msg) \ MessageBoxA(0, msg, __FUNCTION__, MB_OK | MB_TASKMODAL) + + +#ifndef NDEBUG + +#ifdef ASSERT + #undef ASSERT +#endif + +/* HACK for testing */ +#include <stdio.h> + +#define TRACE_(...) \ + { \ + printf(" %s: ", __FUNCTION__); \ + printf(__VA_ARGS__); \ + } + +#define WARN_(...) \ + { \ + printf("o %s: ", __FUNCTION__); \ + printf(__VA_ARGS__); \ + } + +#define ERR_(...) \ + { \ + printf("X %s: ", __FUNCTION__); \ + printf(__VA_ARGS__); \ + } + +#define ASSERT(x) \ + { \ + if ( ! (x) ) \ + { \ + ERR_("ASSERT failed! %s\n", #x); \ + exit(1); \ + } \ + } + +#endif /* Modified: branches/silverblade-audio/lib/drivers/sound/mmebuddy/devices.c URL:
http://svn.reactos.org/svn/reactos/branches/silverblade-audio/lib/drivers/s…
============================================================================== --- branches/silverblade-audio/lib/drivers/sound/mmebuddy/devices.c [iso-8859-1] (original) +++ branches/silverblade-audio/lib/drivers/sound/mmebuddy/devices.c [iso-8859-1] Fri Jul 11 19:49:34 2008 @@ -23,7 +23,6 @@ #include <windows.h> #include <ntddsnd.h> -#include <debug.h> #include <mmebuddy.h> @@ -79,7 +78,7 @@ PSOUND_DEVICE NewDevice; UCHAR TypeIndex; - DPRINT("Adding a sound device to list %d\n", DeviceType); + TRACE_("Adding a sound device to list %d\n", DeviceType); if ( ! VALID_SOUND_DEVICE_TYPE(DeviceType) ) { @@ -126,14 +125,14 @@ /* Start or add to list */ if ( ! SoundDeviceLists[TypeIndex] ) { - DPRINT("Starting device list\n"); + TRACE_("Starting device list\n"); SoundDeviceLists[TypeIndex] = NewDevice; } else { PSOUND_DEVICE CurrentDevice = SoundDeviceLists[TypeIndex]; - DPRINT("Adding to device list\n"); + TRACE_("Adding to device list\n"); while ( CurrentDevice != NULL ) { @@ -148,7 +147,7 @@ } ++ SoundDeviceTotals[TypeIndex]; - DPRINT("Now %d devices of type %d\n", SoundDeviceTotals[TypeIndex], DeviceType); + TRACE_("Now %d devices of type %d\n", (int) SoundDeviceTotals[TypeIndex], DeviceType); return TRUE; } @@ -162,7 +161,7 @@ PSOUND_DEVICE CurrentDevice = NULL; PSOUND_DEVICE PreviousDevice = NULL; - /*DPRINT("Removing a sound device from list %d\n", DeviceType);*/ + /*TRACE_("Removing a sound device from list %d\n", DeviceType);*/ if ( ! SoundDevice ) return MMSYSERR_INVALPARAM; @@ -221,11 +220,11 @@ { PSOUND_DEVICE CurrentDevice; - DPRINT("Emptying device list for device type %d\n", DeviceType); + TRACE_("Emptying device list for device type %d\n", DeviceType); if ( ! VALID_SOUND_DEVICE_TYPE(DeviceType) ) { - DPRINT("Invalid device type - %d\n", DeviceType); + ERR_("Invalid device type - %d\n", DeviceType); return MMSYSERR_INVALPARAM; } @@ -252,7 +251,7 @@ { ULONG i; - DPRINT("Emptying all device lists\n"); + TRACE_("Emptying all device lists\n"); for ( i = MIN_SOUND_DEVICE_TYPE; i <= MAX_SOUND_DEVICE_TYPE; ++ i ) { @@ -526,7 +525,7 @@ DWORD AccessRights = GENERIC_READ; MMRESULT Result; - DPRINT("Default instance ctor"); + TRACE_("Default instance ctor"); ASSERT(SoundDeviceInstance != NULL); GetSoundDeviceFromInstance(SoundDeviceInstance, &SoundDevice); @@ -547,7 +546,7 @@ if ( Result != MMSYSERR_NOERROR ) return Result; - DPRINT("Returning from default ctor"); + TRACE_("Returning from default ctor"); return MMSYSERR_NOERROR; } @@ -560,7 +559,7 @@ PSOUND_DEVICE SoundDevice; MMRESULT Result; - DPRINT("Default instance dtor"); + TRACE_("Default instance dtor"); ASSERT(SoundDeviceInstance); GetSoundDeviceFromInstance(SoundDeviceInstance, &SoundDevice); Modified: branches/silverblade-audio/lib/drivers/sound/mmebuddy/instances.c URL:
http://svn.reactos.org/svn/reactos/branches/silverblade-audio/lib/drivers/s…
============================================================================== --- branches/silverblade-audio/lib/drivers/sound/mmebuddy/instances.c [iso-8859-1] (original) +++ branches/silverblade-audio/lib/drivers/sound/mmebuddy/instances.c [iso-8859-1] Fri Jul 11 19:49:34 2008 @@ -15,7 +15,6 @@ #include <windows.h> #include <ntddsnd.h> -#include <debug.h> #include <mmebuddy.h> @@ -161,9 +160,9 @@ Result = SoundDevice->Functions.Constructor(CreatedInstance); if ( Result != MMSYSERR_NOERROR ) { - DPRINT("Custom ctor returned failure - unlisting"); + ERR_("Custom ctor returned failure - unlisting"); UnlistSoundDeviceInstance(CreatedInstance); - DPRINT("Freeing"); + TRACE_("Freeing"); FreeSoundDeviceInstance(CreatedInstance); CreatedInstance = NULL; //DestroySoundDeviceInstance(CreatedInstance); Modified: branches/silverblade-audio/lib/drivers/sound/mmebuddy/kernel.c URL:
http://svn.reactos.org/svn/reactos/branches/silverblade-audio/lib/drivers/s…
============================================================================== --- branches/silverblade-audio/lib/drivers/sound/mmebuddy/kernel.c [iso-8859-1] (original) +++ branches/silverblade-audio/lib/drivers/sound/mmebuddy/kernel.c [iso-8859-1] Fri Jul 11 19:49:34 2008 @@ -15,7 +15,6 @@ #include <windows.h> #include <mmsystem.h> #include <ntddsnd.h> -#include <debug.h> #include <mmebuddy.h> @@ -30,13 +29,13 @@ if ( ! Handle ) { - DPRINT("No handle ptr\n"); + ERR_("No handle ptr\n"); return MMSYSERR_INVALPARAM; } if ( ! DeviceName ) { - DPRINT("No device name\n"); + ERR_("No device name\n"); return MMSYSERR_INVALPARAM; } @@ -45,7 +44,7 @@ OpenFlags = FILE_FLAG_OVERLAPPED; } - DPRINT("Attempting to open '%s'\n", DeviceName); + /*TRACE_("Attempting to open '%ws'\n", DeviceName);*/ *Handle = CreateFile(DeviceName, AccessRights, @@ -57,7 +56,7 @@ if ( *Handle == INVALID_HANDLE_VALUE ) { - DPRINT("Failed to open\n"); + ERR_("Failed to open\n"); return Win32ErrorToMmResult(GetLastError()); } @@ -73,13 +72,13 @@ if ( ! SoundDevice ) { - DPRINT("No sound device specified"); + ERR_("No sound device specified"); return MMSYSERR_INVALPARAM; } if ( SoundDevice->Handle != INVALID_HANDLE_VALUE ) { - DPRINT("Already open?"); + ERR_("Already open?"); return MMSYSERR_ERROR; /*MMSYSERR_ALLOC;*/ } @@ -217,14 +216,14 @@ { if ( ( ! SoundDeviceInstance ) || ( ! Buffer ) || ( BufferSize == 0 ) ) { - DPRINT("Invalid parameter in WriteSoundDeviceBuffer!\n"); + ERR_("Invalid parameter in WriteSoundDeviceBuffer!\n"); return MMSYSERR_INVALPARAM; } /*wsprintf(msg, L"Writing to handle %x", SoundDeviceInstance->Device->Handle);*/ /*SOUND_DEBUG(msg);*/ - DPRINT("WriteFileEx(%p, %p, %d, %p, %p)\n", + TRACE_("WriteFileEx(%p, %p, %d, %p, %p)\n", SoundDeviceInstance->Device->Handle, Buffer, (int) BufferSize, @@ -237,7 +236,7 @@ Overlapped, CompletionRoutine) ) { - DPRINT("WriteFileEx -- Win32 Error %d", GetLastError()); + ERR_("WriteFileEx -- Win32 Error %d", (int) GetLastError()); return Win32ErrorToMmResult(GetLastError()); } Modified: branches/silverblade-audio/lib/drivers/sound/mmebuddy/mme/auxMessage.c URL:
http://svn.reactos.org/svn/reactos/branches/silverblade-audio/lib/drivers/s…
============================================================================== --- branches/silverblade-audio/lib/drivers/sound/mmebuddy/mme/auxMessage.c [iso-8859-1] (original) +++ branches/silverblade-audio/lib/drivers/sound/mmebuddy/mme/auxMessage.c [iso-8859-1] Fri Jul 11 19:49:34 2008 @@ -15,7 +15,8 @@ #include <windows.h> #include <mmsystem.h> #include <mmddk.h> -#include <debug.h> + +#include <mmebuddy.h> APIENTRY DWORD auxMessage( @@ -25,7 +26,7 @@ DWORD parameter1, DWORD parameter2) { - DPRINT("auxMessageStub called\n"); + TRACE_("auxMessageStub called\n"); /* TODO */ return MMSYSERR_NOTSUPPORTED; } Modified: branches/silverblade-audio/lib/drivers/sound/mmebuddy/mme/midMessage.c URL:
http://svn.reactos.org/svn/reactos/branches/silverblade-audio/lib/drivers/s…
============================================================================== --- branches/silverblade-audio/lib/drivers/sound/mmebuddy/mme/midMessage.c [iso-8859-1] (original) +++ branches/silverblade-audio/lib/drivers/sound/mmebuddy/mme/midMessage.c [iso-8859-1] Fri Jul 11 19:49:34 2008 @@ -15,7 +15,8 @@ #include <windows.h> #include <mmsystem.h> #include <mmddk.h> -#include <debug.h> + +#include <mmebuddy.h> APIENTRY DWORD midMessage( @@ -25,7 +26,7 @@ DWORD parameter1, DWORD parameter2) { - DPRINT("midMessageStub called\n"); + TRACE_("midMessageStub called\n"); switch ( message ) { Modified: branches/silverblade-audio/lib/drivers/sound/mmebuddy/mme/modMessage.c URL:
http://svn.reactos.org/svn/reactos/branches/silverblade-audio/lib/drivers/s…
============================================================================== --- branches/silverblade-audio/lib/drivers/sound/mmebuddy/mme/modMessage.c [iso-8859-1] (original) +++ branches/silverblade-audio/lib/drivers/sound/mmebuddy/mme/modMessage.c [iso-8859-1] Fri Jul 11 19:49:34 2008 @@ -15,7 +15,8 @@ #include <windows.h> #include <mmsystem.h> #include <mmddk.h> -#include <debug.h> + +#include <mmebuddy.h> APIENTRY DWORD modMessage( @@ -25,7 +26,7 @@ DWORD parameter1, DWORD parameter2) { - DPRINT("modMessageStub called\n"); + TRACE_("modMessageStub called\n"); switch ( message ) { Modified: branches/silverblade-audio/lib/drivers/sound/mmebuddy/mme/mxdMessage.c URL:
http://svn.reactos.org/svn/reactos/branches/silverblade-audio/lib/drivers/s…
============================================================================== --- branches/silverblade-audio/lib/drivers/sound/mmebuddy/mme/mxdMessage.c [iso-8859-1] (original) +++ branches/silverblade-audio/lib/drivers/sound/mmebuddy/mme/mxdMessage.c [iso-8859-1] Fri Jul 11 19:49:34 2008 @@ -15,7 +15,8 @@ #include <windows.h> #include <mmsystem.h> #include <mmddk.h> -#include <debug.h> + +#include <mmebuddy.h> APIENTRY DWORD mxdMessage( @@ -25,7 +26,7 @@ DWORD parameter1, DWORD parameter2) { - DPRINT("mxdMessageStub called\n"); + TRACE_("mxdMessageStub called\n"); /* TODO */ return MMSYSERR_NOTSUPPORTED; } Modified: branches/silverblade-audio/lib/drivers/sound/mmebuddy/mme/widMessage.c URL:
http://svn.reactos.org/svn/reactos/branches/silverblade-audio/lib/drivers/s…
============================================================================== --- branches/silverblade-audio/lib/drivers/sound/mmebuddy/mme/widMessage.c [iso-8859-1] (original) +++ branches/silverblade-audio/lib/drivers/sound/mmebuddy/mme/widMessage.c [iso-8859-1] Fri Jul 11 19:49:34 2008 @@ -15,7 +15,6 @@ #include <windows.h> #include <mmsystem.h> #include <mmddk.h> -#include <debug.h> #include <ntddsnd.h> #include <mmebuddy.h> @@ -28,7 +27,7 @@ DWORD parameter1, DWORD parameter2) { - DPRINT("widMessageStub called\n"); + TRACE_("widMessageStub called\n"); switch ( message ) { Modified: branches/silverblade-audio/lib/drivers/sound/mmebuddy/mme/wodMessage.c URL:
http://svn.reactos.org/svn/reactos/branches/silverblade-audio/lib/drivers/s…
============================================================================== --- branches/silverblade-audio/lib/drivers/sound/mmebuddy/mme/wodMessage.c [iso-8859-1] (original) +++ branches/silverblade-audio/lib/drivers/sound/mmebuddy/mme/wodMessage.c [iso-8859-1] Fri Jul 11 19:49:34 2008 @@ -15,7 +15,6 @@ #include <windows.h> #include <mmsystem.h> #include <mmddk.h> -#include <debug.h> #include <ntddsnd.h> #include <mmebuddy.h> @@ -33,7 +32,7 @@ PSOUND_DEVICE_INSTANCE Instance = (PSOUND_DEVICE_INSTANCE)private_handle; - DPRINT("wodMessageStub called\n"); + TRACE_("wodMessageStub called\n"); switch ( message ) { @@ -64,7 +63,7 @@ { WAVEOPENDESC* OpenParameters = (WAVEOPENDESC*) parameter1; - DPRINT("In WODM_OPEN\n"); + TRACE_("In WODM_OPEN\n"); Result = GetSoundDevice(WAVE_OUT_DEVICE_TYPE, device_id, &Device); if ( Result != MMSYSERR_NOERROR ) return Result; Modified: branches/silverblade-audio/lib/drivers/sound/mmebuddy/nt4.c URL:
http://svn.reactos.org/svn/reactos/branches/silverblade-audio/lib/drivers/s…
============================================================================== --- branches/silverblade-audio/lib/drivers/sound/mmebuddy/nt4.c [iso-8859-1] (original) +++ branches/silverblade-audio/lib/drivers/sound/mmebuddy/nt4.c [iso-8859-1] Fri Jul 11 19:49:34 2008 @@ -20,7 +20,6 @@ #include <windows.h> #include <mmsystem.h> #include <ntddsnd.h> -#include <debug.h> #include <mmebuddy.h> @@ -289,7 +288,7 @@ HANDLE DeviceHandle; BOOLEAN DoSearch = TRUE; - DPRINT("Detecting NT4 style sound devices of type %d\n", DeviceType); + TRACE_("Detecting NT4 style sound devices of type %d\n", DeviceType); if ( ! VALID_SOUND_DEVICE_TYPE(DeviceType) ) { Modified: branches/silverblade-audio/lib/drivers/sound/mmebuddy/thread.c URL:
http://svn.reactos.org/svn/reactos/branches/silverblade-audio/lib/drivers/s…
============================================================================== --- branches/silverblade-audio/lib/drivers/sound/mmebuddy/thread.c [iso-8859-1] (original) +++ branches/silverblade-audio/lib/drivers/sound/mmebuddy/thread.c [iso-8859-1] Fri Jul 11 19:49:34 2008 @@ -18,8 +18,6 @@ #include <windows.h> #include <mmsystem.h> -#include <debug.h> - #include <mmebuddy.h> static BOOLEAN ThreadRunning = FALSE; @@ -52,7 +50,7 @@ PSOUND_THREAD_COMPLETED_IO CompletionData; PSOUND_THREAD_OVERLAPPED SoundOverlapped; - DPRINT("** I/O has completed\n"); + TRACE_("** I/O has completed\n"); SoundOverlapped = (PSOUND_THREAD_OVERLAPPED) lpOverlapped; ASSERT(SoundOverlapped); @@ -65,9 +63,9 @@ /* Is this the first completion? */ if ( ! CompletedIoListHead ) { - DPRINT("First completion - making new head and tail\n"); + TRACE_("First completion - making new head and tail\n"); /* This is the first completion */ - ASSERT(CompletedIoListTail); + ASSERT(! CompletedIoListTail); CompletionData->Previous = NULL; CompletionData->Next = NULL; @@ -77,7 +75,7 @@ } else { - DPRINT("Not the first completion - making new tail\n"); + TRACE_("Not the first completion - making new tail\n"); ASSERT(CompletionData); /* This is not the first completion */ CompletionData->Previous = CompletedIoListTail; @@ -92,7 +90,7 @@ /* We keep the completion data, but no longer need this: */ FreeMemory(SoundOverlapped); - DPRINT("** Leaving completion routine\n"); + TRACE_("** Leaving completion routine\n"); } MMRESULT @@ -138,7 +136,7 @@ Overlapped->CompletionData->Parameter = CompletionParameter; Overlapped->CompletionData->BytesTransferred = 0; - DPRINT("Performing overlapped I/O\n"); + TRACE_("Performing overlapped I/O\n"); return WriteSoundDeviceBuffer(SoundDeviceInstance, Buffer, BufferSize, @@ -151,7 +149,7 @@ IN PSOUND_DEVICE_INSTANCE SoundDeviceInstance OPTIONAL, IN PVOID Parameter OPTIONAL) { - DPRINT("ProcessThreadExitRequest called\n"); + TRACE_("ProcessThreadExitRequest called\n"); ThreadRunning = FALSE; return MMSYSERR_NOERROR; } @@ -198,24 +196,24 @@ PSOUND_THREAD_COMPLETED_IO CurrentCompletion; /* Process the I/O Completion */ - DPRINT("Returned from I/O completion APC\n"); + TRACE_("Returned from I/O completion APC\n"); CurrentCompletion = CompletedIoListHead; ASSERT(CurrentCompletion); - DPRINT("Beginning enumeration of completions\n"); + TRACE_("Beginning enumeration of completions\n"); while ( CurrentCompletion ) { PSOUND_THREAD_COMPLETED_IO PreviousCompletion; - DPRINT("Calling completion handler\n"); + TRACE_("Calling completion handler\n"); /* Call the completion handler */ CurrentCompletion->CompletionHandler( CurrentCompletion->SoundDeviceInstance, CurrentCompletion->Parameter, CurrentCompletion->BytesTransferred); - DPRINT("Advancing to next completion\n"); + TRACE_("Advancing to next completion\n"); /* Get the next completion but destroy the previous */ PreviousCompletion = CurrentCompletion; CurrentCompletion = CurrentCompletion->Next; @@ -227,7 +225,7 @@ /* Nothing in the completion queue/list now */ CompletedIoListHead = NULL; CompletedIoListTail = NULL; - DPRINT("Ended enumeration of completions\n"); + TRACE_("Ended enumeration of completions\n"); } else { @@ -236,7 +234,7 @@ } } - DPRINT("THREAD: Exiting\n"); + TRACE_("THREAD: Exiting\n"); ExitThread(0); return 0; @@ -321,7 +319,7 @@ return Win32ErrorToMmResult(GetLastError()); } - DPRINT("Starting sound thread\n"); + TRACE_("Starting sound thread\n"); /* We're all set to go, so let's start the thread up */ ResumeThread(SoundThread); @@ -373,20 +371,20 @@ return MMSYSERR_ERROR; } - DPRINT("Calling thread shutdown function\n"); + TRACE_("Calling thread shutdown function\n"); Result = CallUsingSoundThread(NULL, ProcessThreadExitRequest, NULL); /* Our request didn't get processed? */ - ASSERT(Result != MMSYSERR_NOERROR); + ASSERT(Result == MMSYSERR_NOERROR); if ( Result != MMSYSERR_NOERROR ) return Result; WaitForSingleObject(SoundThread, INFINITE); - DPRINT("Sound thread has quit\n"); + TRACE_("Sound thread has quit\n"); /* Clean up */ CloseHandle(SoundThread); Modified: branches/silverblade-audio/lib/drivers/sound/mmebuddy/utility.c URL:
http://svn.reactos.org/svn/reactos/branches/silverblade-audio/lib/drivers/s…
============================================================================== --- branches/silverblade-audio/lib/drivers/sound/mmebuddy/utility.c [iso-8859-1] (original) +++ branches/silverblade-audio/lib/drivers/sound/mmebuddy/utility.c [iso-8859-1] Fri Jul 11 19:49:34 2008 @@ -14,7 +14,6 @@ #include <windows.h> #include <mmsystem.h> -#include <debug.h> #include <mmebuddy.h> Modified: branches/silverblade-audio/lib/drivers/sound/mmebuddy/wave/wavethread.c URL:
http://svn.reactos.org/svn/reactos/branches/silverblade-audio/lib/drivers/s…
============================================================================== --- branches/silverblade-audio/lib/drivers/sound/mmebuddy/wave/wavethread.c [iso-8859-1] (original) +++ branches/silverblade-audio/lib/drivers/sound/mmebuddy/wave/wavethread.c [iso-8859-1] Fri Jul 11 19:49:34 2008 @@ -18,7 +18,6 @@ #include <windows.h> #include <mmsystem.h> -#include <debug.h> #include <mmebuddy.h> @@ -65,7 +64,7 @@ PWAVE_STREAM_INFO StreamInfo; DWORD BytesToStream, BytesStreamed = 0; - DPRINT("PerformWaveIo\n"); + TRACE_("PerformWaveIo\n"); ASSERT(SoundDeviceInstance); @@ -74,7 +73,7 @@ /* If we're out of buffers, mark stream as stopped and do nothing */ if ( ! StreamInfo->CurrentBuffer ) { - DPRINT("*** NOTHING TO DO ***\n"); + TRACE_("*** NOTHING TO DO ***\n"); return 0; } @@ -83,9 +82,9 @@ StreamInfo->CurrentBuffer->reserved, MAX_SOUND_BUFFER_SIZE); - DPRINT("About to report what I'm about to write...\n"); - - DPRINT("Writing %p + %d (%d bytes) - buffer length is %d bytes\n", + TRACE_("About to report what I'm about to write...\n"); + + TRACE_("Writing %p + %d (%d bytes) - buffer length is %d bytes\n", StreamInfo->CurrentBuffer->lpData, (int) StreamInfo->CurrentBuffer->reserved, (int) BytesToStream, @@ -109,7 +108,7 @@ if ( StreamInfo->CurrentBuffer->reserved == StreamInfo->CurrentBuffer->dwBufferLength ) { - DPRINT("Advancing to next buffer\n"); + TRACE_("Advancing to next buffer\n"); StreamInfo->CurrentBuffer = StreamInfo->CurrentBuffer->lpNext; } @@ -128,14 +127,14 @@ StreamInfo = &SoundDeviceInstance->Streaming.Wave; - DPRINT("<== Streaming wave I/O ==>\n"); + TRACE_("<== Streaming wave I/O ==>\n"); while ( StreamReadyForData(StreamInfo) && StreamHasBuffersQueued(StreamInfo) ) { - DPRINT("Performing wave I/O ...\n"); + TRACE_("Performing wave I/O ...\n"); PerformWaveIo(SoundDeviceInstance); } - DPRINT("<== Done streaming ==>\n"); + TRACE_("<== Done streaming ==>\n"); return MMSYSERR_NOERROR; } @@ -148,7 +147,7 @@ { PWAVE_STREAM_INFO StreamInfo; - DPRINT("CompleteWaveBuffer(%p, %p, %d)\n", + TRACE_("CompleteWaveBuffer(%p, %p, %d)\n", SoundDeviceInstance, Parameter, (int) BytesWritten); @@ -163,7 +162,7 @@ PerformWaveIo(SoundDeviceInstance); - DPRINT("Wave completion routine done\n"); + TRACE_("Wave completion routine done\n"); } MMRESULT @@ -183,7 +182,7 @@ /* To avoid stupidly long variable names we alias this */ StreamInfo = &SoundDeviceInstance->Streaming.Wave; - DPRINT("QueueBuffer_Request\n"); + TRACE_("QueueBuffer_Request\n"); /* Initialise fields of interest to us */ WaveHeader->lpNext = NULL; @@ -195,7 +194,7 @@ */ if ( ! StreamInfo->BufferQueueHead ) { - DPRINT("This is the first buffer being queued\n"); + TRACE_("This is the first buffer being queued\n"); /* Set head, tail and current to this buffer */ StreamInfo->BufferQueueHead = WaveHeader; @@ -212,7 +211,7 @@ } else { - DPRINT("This is not the first buffer being queued\n"); + TRACE_("This is not the first buffer being queued\n"); /* Point the existing tail to the new buffer */ StreamInfo->BufferQueueTail->lpNext = WaveHeader;
16 years, 5 months
1
0
0
0
[silverblade] 34431: Removed custom debug printing macros and replaced with DPRINTs.
by silverblade@svn.reactos.org
Author: silverblade Date: Fri Jul 11 18:45:12 2008 New Revision: 34431 URL:
http://svn.reactos.org/svn/reactos?rev=34431&view=rev
Log: Removed custom debug printing macros and replaced with DPRINTs. Modified: branches/silverblade-audio/dll/win32/mmdrv/testing.c branches/silverblade-audio/dll/win32/sndblst/sndblst.c branches/silverblade-audio/include/reactos/libs/sound/mmebuddy.h branches/silverblade-audio/lib/drivers/sound/mmebuddy/devices.c branches/silverblade-audio/lib/drivers/sound/mmebuddy/instances.c branches/silverblade-audio/lib/drivers/sound/mmebuddy/kernel.c branches/silverblade-audio/lib/drivers/sound/mmebuddy/mme/wodMessage.c branches/silverblade-audio/lib/drivers/sound/mmebuddy/thread.c branches/silverblade-audio/lib/drivers/sound/mmebuddy/utility.c branches/silverblade-audio/lib/drivers/sound/mmebuddy/wave/wavethread.c Modified: branches/silverblade-audio/dll/win32/mmdrv/testing.c URL:
http://svn.reactos.org/svn/reactos/branches/silverblade-audio/dll/win32/mmd…
============================================================================== --- branches/silverblade-audio/dll/win32/mmdrv/testing.c [iso-8859-1] (original) +++ branches/silverblade-audio/dll/win32/mmdrv/testing.c [iso-8859-1] Fri Jul 11 18:45:12 2008 @@ -212,11 +212,11 @@ /* Report the number of wave output devices */ NumWaveOuts = wodMessage(0, WODM_GETNUMDEVS, 0, 0, 0); - SOUND_DEBUG_HEX(NumWaveOuts); + DPRINT("Wave outs = %d\n", NumWaveOuts); if ( NumWaveOuts < 1 ) { - SOUND_DEBUG(L"Nothing to do as no waveout devices!"); + DPRINT("Nothing to do as no waveout devices!"); return; } Modified: branches/silverblade-audio/dll/win32/sndblst/sndblst.c URL:
http://svn.reactos.org/svn/reactos/branches/silverblade-audio/dll/win32/snd…
============================================================================== --- branches/silverblade-audio/dll/win32/sndblst/sndblst.c [iso-8859-1] (original) +++ branches/silverblade-audio/dll/win32/sndblst/sndblst.c [iso-8859-1] Fri Jul 11 18:45:12 2008 @@ -108,7 +108,8 @@ RemoveAllSoundDevices(); - SOUND_DEBUG_HEX(GetMemoryAllocations()); +// SOUND_DEBUG_HEX(GetMemoryAllocations()); + DPRINT("Leaving driver with %d memory allocations present\n", GetMemoryAllocations()); return 1L; @@ -179,9 +180,9 @@ //SOUND_DEBUG(L"WODM_OPEN test 2"); OpenDesc.lpFormat = &Format; Result = wodMessage(0, WODM_OPEN, (DWORD) &InstanceData, (DWORD) &OpenDesc, 0); - SOUND_DEBUG_HEX(Result); - - SOUND_DEBUG(L"WODM_WRITE test"); + /*SOUND_DEBUG_HEX(Result);*/ + + POPUP("Click for WODM_WRITE test"); WaveHeaders[0].lpData = (PVOID) Buffer; WaveHeaders[0].dwBufferLength = 1000000; WaveHeaders[0].dwFlags = WHDR_PREPARED; @@ -216,9 +217,9 @@ // SOUND_DEBUG_HEX(Result); - SOUND_DEBUG(L"WODM_CLOSE test"); + POPUP("Click for WODM_CLOSE test"); Result = wodMessage(0, WODM_CLOSE, (DWORD) InstanceData, (DWORD) 0, 0); - SOUND_DEBUG_HEX(Result); + /* SOUND_DEBUG_HEX(Result); */ /* DRV_UNLOAD */ DriverProc(0, 0, DRV_FREE, 0, 0); Modified: branches/silverblade-audio/include/reactos/libs/sound/mmebuddy.h URL:
http://svn.reactos.org/svn/reactos/branches/silverblade-audio/include/react…
============================================================================== --- branches/silverblade-audio/include/reactos/libs/sound/mmebuddy.h [iso-8859-1] (original) +++ branches/silverblade-audio/include/reactos/libs/sound/mmebuddy.h [iso-8859-1] Fri Jul 11 18:45:12 2008 @@ -22,43 +22,12 @@ Hacky debug macro */ -#include <stdio.h> -#define SOUND_TRACE printf - -#define SOUND_DEBUG(x) \ - MessageBox(0, x, L"Debug", MB_OK | MB_TASKMODAL); - -#define SOUND_DEBUG_HEX(x) \ - { \ - WCHAR dbgmsg[1024], dbgtitle[1024]; \ - wsprintf(dbgtitle, L"%hS[%d]", __FILE__, __LINE__); \ - wsprintf(dbgmsg, L"%hS == %x", #x, x); \ - MessageBox(0, dbgmsg, dbgtitle, MB_OK | MB_TASKMODAL); \ - } - -#define SOUND_ASSERT(x) \ - { \ - if ( ! ( x ) ) \ - { \ - WCHAR dbgmsg[1024], dbgtitle[1024]; \ - wsprintf(dbgtitle, L"%hS[%d]", __FILE__, __LINE__); \ - wsprintf(dbgmsg, L"ASSERT FAILED:\n%hS", #x); \ - MessageBox(0, dbgmsg, dbgtitle, MB_OK | MB_TASKMODAL); \ - exit(1); \ - } \ - } +#define POPUP(msg) \ + MessageBoxA(0, msg, __FUNCTION__, MB_OK | MB_TASKMODAL) /* Some memory allocation helper macros -*/ - -/* -#define AllocateMemory(size) \ - HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, size) - -#define FreeMemory(ptr) \ - HeapFree(GetProcessHeap(), 0, ptr) */ #define AllocateMemoryFor(thing) \ Modified: branches/silverblade-audio/lib/drivers/sound/mmebuddy/devices.c URL:
http://svn.reactos.org/svn/reactos/branches/silverblade-audio/lib/drivers/s…
============================================================================== --- branches/silverblade-audio/lib/drivers/sound/mmebuddy/devices.c [iso-8859-1] (original) +++ branches/silverblade-audio/lib/drivers/sound/mmebuddy/devices.c [iso-8859-1] Fri Jul 11 18:45:12 2008 @@ -196,7 +196,7 @@ { if ( CurrentDevice == SoundDevice ) { - SOUND_ASSERT(PreviousDevice != NULL); + ASSERT(PreviousDevice != NULL); PreviousDevice->Next = CurrentDevice->Next; break; @@ -526,17 +526,17 @@ DWORD AccessRights = GENERIC_READ; MMRESULT Result; - SOUND_DEBUG(L"Default instance ctor"); - - SOUND_ASSERT(SoundDeviceInstance != NULL); + DPRINT("Default instance ctor"); + + ASSERT(SoundDeviceInstance != NULL); GetSoundDeviceFromInstance(SoundDeviceInstance, &SoundDevice); - SOUND_ASSERT(SoundDevice != NULL); + ASSERT(SoundDevice != NULL); /* If this fails, we have an internal error somewhere */ Result = GetSoundDeviceType(SoundDevice, &DeviceType); if ( Result != MMSYSERR_NOERROR ) { - SOUND_ASSERT(Result != MMSYSERR_NOERROR); + ASSERT(Result != MMSYSERR_NOERROR); return MMSYSERR_ERROR; } @@ -547,7 +547,7 @@ if ( Result != MMSYSERR_NOERROR ) return Result; - SOUND_DEBUG(L"Returning from default ctor"); + DPRINT("Returning from default ctor"); return MMSYSERR_NOERROR; } @@ -560,11 +560,11 @@ PSOUND_DEVICE SoundDevice; MMRESULT Result; - SOUND_DEBUG(L"Default instance dtor"); - - SOUND_ASSERT(SoundDeviceInstance); + DPRINT("Default instance dtor"); + + ASSERT(SoundDeviceInstance); GetSoundDeviceFromInstance(SoundDeviceInstance, &SoundDevice); - SOUND_ASSERT(SoundDevice); + ASSERT(SoundDevice); Result = CloseKernelSoundDevice(SoundDevice); Modified: branches/silverblade-audio/lib/drivers/sound/mmebuddy/instances.c URL:
http://svn.reactos.org/svn/reactos/branches/silverblade-audio/lib/drivers/s…
============================================================================== --- branches/silverblade-audio/lib/drivers/sound/mmebuddy/instances.c [iso-8859-1] (original) +++ branches/silverblade-audio/lib/drivers/sound/mmebuddy/instances.c [iso-8859-1] Fri Jul 11 18:45:12 2008 @@ -66,9 +66,9 @@ { PSOUND_DEVICE_INSTANCE CurrentInstance = NULL; - SOUND_ASSERT(SoundDevice != NULL); - SOUND_ASSERT(SoundDeviceInstance != NULL); - SOUND_ASSERT(SoundDeviceInstance->Device == NULL); + ASSERT(SoundDevice != NULL); + ASSERT(SoundDeviceInstance != NULL); + ASSERT(SoundDeviceInstance->Device == NULL); SoundDeviceInstance->Device = SoundDevice; @@ -161,9 +161,9 @@ Result = SoundDevice->Functions.Constructor(CreatedInstance); if ( Result != MMSYSERR_NOERROR ) { - SOUND_DEBUG(L"Custom ctor returned failure - unlisting"); + DPRINT("Custom ctor returned failure - unlisting"); UnlistSoundDeviceInstance(CreatedInstance); - SOUND_DEBUG(L"Freeing"); + DPRINT("Freeing"); FreeSoundDeviceInstance(CreatedInstance); CreatedInstance = NULL; //DestroySoundDeviceInstance(CreatedInstance); Modified: branches/silverblade-audio/lib/drivers/sound/mmebuddy/kernel.c URL:
http://svn.reactos.org/svn/reactos/branches/silverblade-audio/lib/drivers/s…
============================================================================== --- branches/silverblade-audio/lib/drivers/sound/mmebuddy/kernel.c [iso-8859-1] (original) +++ branches/silverblade-audio/lib/drivers/sound/mmebuddy/kernel.c [iso-8859-1] Fri Jul 11 18:45:12 2008 @@ -30,13 +30,13 @@ if ( ! Handle ) { - MessageBox(0, L"Failed handle", L"kernel.c", MB_OK | MB_TASKMODAL); + DPRINT("No handle ptr\n"); return MMSYSERR_INVALPARAM; } if ( ! DeviceName ) { - MessageBox(0, L"Failed devname", L"kernel.c", MB_OK | MB_TASKMODAL); + DPRINT("No device name\n"); return MMSYSERR_INVALPARAM; } @@ -45,8 +45,7 @@ OpenFlags = FILE_FLAG_OVERLAPPED; } - DPRINT("Attempting to open '%ws'\n", DeviceName); - MessageBox(0, DeviceName, L"Attempting to open", MB_OK | MB_TASKMODAL); + DPRINT("Attempting to open '%s'\n", DeviceName); *Handle = CreateFile(DeviceName, AccessRights, @@ -58,6 +57,7 @@ if ( *Handle == INVALID_HANDLE_VALUE ) { + DPRINT("Failed to open\n"); return Win32ErrorToMmResult(GetLastError()); } @@ -73,13 +73,13 @@ if ( ! SoundDevice ) { - SOUND_DEBUG(L"No sound device specified"); + DPRINT("No sound device specified"); return MMSYSERR_INVALPARAM; } if ( SoundDevice->Handle != INVALID_HANDLE_VALUE ) { - SOUND_DEBUG(L"Already open?"); + DPRINT("Already open?"); return MMSYSERR_ERROR; /*MMSYSERR_ALLOC;*/ } @@ -215,22 +215,21 @@ LPOVERLAPPED_COMPLETION_ROUTINE CompletionRoutine, LPOVERLAPPED Overlapped) { - WCHAR msg[128]; if ( ( ! SoundDeviceInstance ) || ( ! Buffer ) || ( BufferSize == 0 ) ) { - SOUND_DEBUG(L"Invalid parameter!\n"); + DPRINT("Invalid parameter in WriteSoundDeviceBuffer!\n"); return MMSYSERR_INVALPARAM; } /*wsprintf(msg, L"Writing to handle %x", SoundDeviceInstance->Device->Handle);*/ /*SOUND_DEBUG(msg);*/ - SOUND_TRACE("WriteFileEx(%p, %p, %d, %p, %p)\n", - SoundDeviceInstance->Device->Handle, - Buffer, - (int) BufferSize, - Overlapped, - CompletionRoutine); + DPRINT("WriteFileEx(%p, %p, %d, %p, %p)\n", + SoundDeviceInstance->Device->Handle, + Buffer, + (int) BufferSize, + Overlapped, + CompletionRoutine); if ( ! WriteFileEx(SoundDeviceInstance->Device->Handle, Buffer, @@ -238,8 +237,7 @@ Overlapped, CompletionRoutine) ) { - wsprintf(msg, L"Win32 Error %d", GetLastError()); - SOUND_DEBUG(msg); + DPRINT("WriteFileEx -- Win32 Error %d", GetLastError()); return Win32ErrorToMmResult(GetLastError()); } Modified: branches/silverblade-audio/lib/drivers/sound/mmebuddy/mme/wodMessage.c URL:
http://svn.reactos.org/svn/reactos/branches/silverblade-audio/lib/drivers/s…
============================================================================== --- branches/silverblade-audio/lib/drivers/sound/mmebuddy/mme/wodMessage.c [iso-8859-1] (original) +++ branches/silverblade-audio/lib/drivers/sound/mmebuddy/mme/wodMessage.c [iso-8859-1] Fri Jul 11 18:45:12 2008 @@ -33,7 +33,7 @@ PSOUND_DEVICE_INSTANCE Instance = (PSOUND_DEVICE_INSTANCE)private_handle; - SOUND_TRACE("wodMessageStub called\n"); + DPRINT("wodMessageStub called\n"); switch ( message ) { @@ -64,7 +64,7 @@ { WAVEOPENDESC* OpenParameters = (WAVEOPENDESC*) parameter1; - SOUND_TRACE("In WODM_OPEN\n"); + DPRINT("In WODM_OPEN\n"); Result = GetSoundDevice(WAVE_OUT_DEVICE_TYPE, device_id, &Device); if ( Result != MMSYSERR_NOERROR ) return Result; @@ -105,12 +105,12 @@ case WODM_CLOSE : { //SOUND_DEBUG_HEX(Instance); - SOUND_ASSERT(Instance != NULL); + ASSERT(Instance != NULL); /* TODO: Ensure its OK to close */ Result = DestroySoundDeviceInstance(Instance); - SOUND_DEBUG_HEX(Result); + /*SOUND_DEBUG_HEX(Result);*/ /* TODO: When do we send the callback? */ @@ -120,8 +120,8 @@ case WODM_WRITE : { - SOUND_ASSERT(Instance != NULL); - SOUND_ASSERT(parameter1 != 0); + ASSERT(Instance != NULL); + ASSERT(parameter1 != 0); return QueueWaveDeviceBuffer(Instance, (PWAVEHDR) parameter1); } Modified: branches/silverblade-audio/lib/drivers/sound/mmebuddy/thread.c URL:
http://svn.reactos.org/svn/reactos/branches/silverblade-audio/lib/drivers/s…
============================================================================== --- branches/silverblade-audio/lib/drivers/sound/mmebuddy/thread.c [iso-8859-1] (original) +++ branches/silverblade-audio/lib/drivers/sound/mmebuddy/thread.c [iso-8859-1] Fri Jul 11 18:45:12 2008 @@ -22,9 +22,6 @@ #include <mmebuddy.h> -/* HAX */ -#include <stdio.h> - static BOOLEAN ThreadRunning = FALSE; static HANDLE SoundThread = INVALID_HANDLE_VALUE; static HANDLE ReadyEvent = INVALID_HANDLE_VALUE; @@ -58,10 +55,10 @@ DPRINT("** I/O has completed\n"); SoundOverlapped = (PSOUND_THREAD_OVERLAPPED) lpOverlapped; - SOUND_ASSERT(SoundOverlapped); + ASSERT(SoundOverlapped); CompletionData = SoundOverlapped->CompletionData; - SOUND_ASSERT(CompletionData); + ASSERT(CompletionData); CompletionData->BytesTransferred = dwNumberOfBytesTransferred; @@ -70,7 +67,7 @@ { DPRINT("First completion - making new head and tail\n"); /* This is the first completion */ - SOUND_ASSERT(CompletedIoListTail == NULL); + ASSERT(CompletedIoListTail); CompletionData->Previous = NULL; CompletionData->Next = NULL; @@ -81,13 +78,13 @@ else { DPRINT("Not the first completion - making new tail\n"); - SOUND_ASSERT(CompletionData); + ASSERT(CompletionData); /* This is not the first completion */ CompletionData->Previous = CompletedIoListTail; CompletionData->Next = NULL; /* Completion data gets made the new tail */ - SOUND_ASSERT(CompletedIoListTail); + ASSERT(CompletedIoListTail); CompletedIoListTail->Next = CompletionData; CompletedIoListTail = CompletionData; } @@ -179,8 +176,8 @@ { /* Process the request */ - SOUND_ASSERT(CurrentRequest.RequestHandler != NULL); - if ( CurrentRequest.RequestHandler != NULL ) + ASSERT(CurrentRequest.RequestHandler); + if ( CurrentRequest.RequestHandler ) { CurrentRequest.ReturnValue = CurrentRequest.RequestHandler( CurrentRequest.SoundDeviceInstance, @@ -201,42 +198,41 @@ PSOUND_THREAD_COMPLETED_IO CurrentCompletion; /* Process the I/O Completion */ - SOUND_TRACE("Returned from I/O completion APC\n"); + DPRINT("Returned from I/O completion APC\n"); CurrentCompletion = CompletedIoListHead; - SOUND_ASSERT(CurrentCompletion); - - SOUND_TRACE("Beginning enumeration of completions\n"); + ASSERT(CurrentCompletion); + + DPRINT("Beginning enumeration of completions\n"); while ( CurrentCompletion ) { PSOUND_THREAD_COMPLETED_IO PreviousCompletion; - SOUND_TRACE("Calling completion handler\n"); + DPRINT("Calling completion handler\n"); /* Call the completion handler */ CurrentCompletion->CompletionHandler( CurrentCompletion->SoundDeviceInstance, CurrentCompletion->Parameter, CurrentCompletion->BytesTransferred); - SOUND_TRACE("Advancing to next completion\n"); + DPRINT("Advancing to next completion\n"); /* Get the next completion but destroy the previous */ PreviousCompletion = CurrentCompletion; CurrentCompletion = CurrentCompletion->Next; /*CompletedIoListHead = CurrentCompletion;*/ - SOUND_TRACE("Freeing memory\n"); FreeMemory(PreviousCompletion); } /* Nothing in the completion queue/list now */ CompletedIoListHead = NULL; CompletedIoListTail = NULL; - SOUND_TRACE("Ended enumeration of completions\n"); + DPRINT("Ended enumeration of completions\n"); } else { /* Shouldn't happen! */ - SOUND_ASSERT(FALSE); + ASSERT(FALSE); } } @@ -342,7 +338,7 @@ if ( ! RequestHandler ) return MMSYSERR_INVALPARAM; - SOUND_ASSERT(SoundThread != INVALID_HANDLE_VALUE); + ASSERT(SoundThread != INVALID_HANDLE_VALUE); if ( SoundThread == INVALID_HANDLE_VALUE ) { return MMSYSERR_ERROR; @@ -371,7 +367,7 @@ { MMRESULT Result; - SOUND_ASSERT(SoundThread != INVALID_HANDLE_VALUE); + ASSERT(SoundThread != INVALID_HANDLE_VALUE); if ( SoundThread == INVALID_HANDLE_VALUE ) { return MMSYSERR_ERROR; @@ -384,7 +380,7 @@ NULL); /* Our request didn't get processed? */ - SOUND_ASSERT(Result != MMSYSERR_NOERROR); + ASSERT(Result != MMSYSERR_NOERROR); if ( Result != MMSYSERR_NOERROR ) return Result; Modified: branches/silverblade-audio/lib/drivers/sound/mmebuddy/utility.c URL:
http://svn.reactos.org/svn/reactos/branches/silverblade-audio/lib/drivers/s…
============================================================================== --- branches/silverblade-audio/lib/drivers/sound/mmebuddy/utility.c [iso-8859-1] (original) +++ branches/silverblade-audio/lib/drivers/sound/mmebuddy/utility.c [iso-8859-1] Fri Jul 11 18:45:12 2008 @@ -14,6 +14,7 @@ #include <windows.h> #include <mmsystem.h> +#include <debug.h> #include <mmebuddy.h> @@ -47,7 +48,8 @@ FreeMemory( IN PVOID Pointer) { - SOUND_ASSERT(ProcessHeapHandle != INVALID_HANDLE_VALUE); + ASSERT(ProcessHeapHandle != INVALID_HANDLE_VALUE); + ASSERT(Pointer); HeapFree(ProcessHeapHandle, 0, Pointer); Modified: branches/silverblade-audio/lib/drivers/sound/mmebuddy/wave/wavethread.c URL:
http://svn.reactos.org/svn/reactos/branches/silverblade-audio/lib/drivers/s…
============================================================================== --- branches/silverblade-audio/lib/drivers/sound/mmebuddy/wave/wavethread.c [iso-8859-1] (original) +++ branches/silverblade-audio/lib/drivers/sound/mmebuddy/wave/wavethread.c [iso-8859-1] Fri Jul 11 18:45:12 2008 @@ -67,13 +67,14 @@ DPRINT("PerformWaveIo\n"); - SOUND_ASSERT(SoundDeviceInstance); - - StreamInfo = &SoundDeviceInstance->Streaming.Wave; - - /* If we're out of buffers, do nothing */ + ASSERT(SoundDeviceInstance); + + StreamInfo = &SoundDeviceInstance->Streaming.Wave; + + /* If we're out of buffers, mark stream as stopped and do nothing */ if ( ! StreamInfo->CurrentBuffer ) { + DPRINT("*** NOTHING TO DO ***\n"); return 0; } @@ -123,7 +124,7 @@ IN PSOUND_DEVICE_INSTANCE SoundDeviceInstance) { PWAVE_STREAM_INFO StreamInfo; - SOUND_ASSERT(SoundDeviceInstance); + ASSERT(SoundDeviceInstance); StreamInfo = &SoundDeviceInstance->Streaming.Wave; @@ -152,12 +153,12 @@ Parameter, (int) BytesWritten); - SOUND_ASSERT(SoundDeviceInstance); + ASSERT(SoundDeviceInstance); StreamInfo = &SoundDeviceInstance->Streaming.Wave; /* Decrease the number of outstanding buffers */ - SOUND_ASSERT(StreamInfo->BuffersOutstanding > 0); + ASSERT(StreamInfo->BuffersOutstanding > 0); -- StreamInfo->BuffersOutstanding; PerformWaveIo(SoundDeviceInstance);
16 years, 5 months
1
0
0
0
[jimtabor] 34430: - Christoph von Wittich spotted a condition when co_MsqPostKeyboardMessage was called from KeyboardThreadMain, the thread was unlocked when waiting in co_MsqSendMessage. The problem; UserLeave was called before waiting on an event. I added checks to verify locking and if not, lock the thread. I'm not sure ATM if co_MsqPostKeyboardMessage should have full locking since it is only used by input.c. - Added IdlePing to wakeup process threads before waiting on events, it look like t
by jimtabor@svn.reactos.org
Author: jimtabor Date: Fri Jul 11 18:07:31 2008 New Revision: 34430 URL:
http://svn.reactos.org/svn/reactos?rev=34430&view=rev
Log: - Christoph von Wittich spotted a condition when co_MsqPostKeyboardMessage was called from KeyboardThreadMain, the thread was unlocked when waiting in co_MsqSendMessage. The problem; UserLeave was called before waiting on an event. I added checks to verify locking and if not, lock the thread. I'm not sure ATM if co_MsqPostKeyboardMessage should have full locking since it is only used by input.c. - Added IdlePing to wakeup process threads before waiting on events, it look like the right place to put them. Modified: trunk/reactos/subsystems/win32/win32k/ntuser/msgqueue.c Modified: trunk/reactos/subsystems/win32/win32k/ntuser/msgqueue.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/win32/win32k/nt…
============================================================================== --- trunk/reactos/subsystems/win32/win32k/ntuser/msgqueue.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/win32/win32k/ntuser/msgqueue.c [iso-8859-1] Fri Jul 11 18:07:31 2008 @@ -64,6 +64,17 @@ /* FUNCTIONS *****************************************************************/ +// +// Wakeup any thread/process waiting on idle input. +// +static VOID FASTCALL +IdlePing(VOID) +{ + PW32PROCESS W32d = PsGetCurrentProcessWin32Process(); + if (W32d && W32d->InputIdleEvent) + KePulseEvent( W32d->InputIdleEvent, EVENT_INCREMENT, TRUE); +} + HANDLE FASTCALL IntMsqSetWakeMask(DWORD WakeMask) { @@ -490,6 +501,8 @@ WaitObjects[0] = &HardwareMessageQueueLock; do { + IdlePing(); + UserLeaveCo(); WaitStatus = KeWaitForMultipleObjects(2, WaitObjects, WaitAny, UserRequest, @@ -690,6 +703,9 @@ END_CLEANUP; } +// +// Note: Only called from input.c. +// VOID FASTCALL co_MsqPostKeyboardMessage(UINT uMsg, WPARAM wParam, LPARAM lParam) { @@ -697,6 +713,9 @@ MSG Msg; LARGE_INTEGER LargeTickCount; KBDLLHOOKSTRUCT KbdHookData; + + // Condition may arise when calling MsqPostMessage and waiting for an event. + if (!UserIsEntered()) UserEnterExclusive(); // Fixme: Not sure ATM if this thread is locked. DPRINT("MsqPostKeyboardMessage(uMsg 0x%x, wParam 0x%x, lParam 0x%x)\n", uMsg, wParam, lParam); @@ -726,14 +745,14 @@ } FocusMessageQueue = IntGetFocusMessageQueue(); - if (FocusMessageQueue == NULL) - { + if (FocusMessageQueue == NULL) + { DPRINT("No focus message queue\n"); return; - } - - if (FocusMessageQueue->FocusWindow != (HWND)0) - { + } + + if (FocusMessageQueue->FocusWindow != (HWND)0) + { Msg.hwnd = FocusMessageQueue->FocusWindow; DPRINT("Msg.hwnd = %x\n", Msg.hwnd); @@ -742,12 +761,13 @@ IntGetCursorLocation(FocusMessageQueue->Desktop->WindowStation, &Msg.pt); MsqPostMessage(FocusMessageQueue, &Msg, FALSE, QS_KEY); - } - else - { + } + else + { DPRINT("Invalid focus window handle\n"); - } - } + } + if (UserIsEntered()) UserLeave(); +} VOID FASTCALL MsqPostHotKeyMessage(PVOID Thread, HWND hWnd, WPARAM wParam, LPARAM lParam) @@ -1087,6 +1107,7 @@ if(Block) { + IdlePing(); UserLeaveCo(); @@ -1149,6 +1170,7 @@ WaitObjects[1] = ThreadQueue->NewMessages; do { + IdlePing(); UserLeaveCo(); @@ -1303,6 +1325,8 @@ { Timeout = NULL; } + + IdlePing(); // Going to wait so send Idle ping. UserLeaveCo();
16 years, 5 months
1
0
0
0
← Newer
1
...
53
54
55
56
57
58
59
...
77
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
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
Results per page:
10
25
50
100
200