Author: cgutman
Date: Sat Jan 9 16:49:39 2010
New Revision: 45015
URL: http://svn.reactos.org/svn/reactos?rev=45015&view=rev
Log:
- Store the address file handle in the IOSB
- MSAFD relies on this behavior to store the address file handle
Modified:
branches/aicom-network-branch/drivers/network/afd/afd/bind.c
Modified: branches/aicom-network-branch/drivers/network/afd/afd/bind.c
URL: http://svn.reactos.org/svn/reactos/branches/aicom-network-branch/drivers/ne…
==============================================================================
--- branches/aicom-network-branch/drivers/network/afd/afd/bind.c [iso-8859-1] (original)
+++ branches/aicom-network-branch/drivers/network/afd/afd/bind.c [iso-8859-1] Sat Jan 9 16:49:39 2010
@@ -101,6 +101,7 @@
if (NT_SUCCESS(Status))
FCB->State = SOCKET_STATE_BOUND;
- return UnlockAndMaybeComplete( FCB, Status, Irp, 0 );
+ /* MSAFD relies on us returning the address file handle in the IOSB */
+ return UnlockAndMaybeComplete( FCB, Status, Irp, (ULONG_PTR)FCB->AddressFile.Handle );
}
Author: jimtabor
Date: Sat Jan 9 07:16:51 2010
New Revision: 45013
URL: http://svn.reactos.org/svn/reactos?rev=45013&view=rev
Log:
[User32]
- Add corrected behavior for SetWindowRgn, delete region object after setting windows region. See bug 4980.
- After a successful call to SetWindowRgn, the system owns the region specified by the region handle hRgn. The system does not make a copy of the region. Thus, you should not make any further function calls with this region handle. In particular, do not delete this region handle. The system deletes the region handle when it no longer needed.
- References : http://msdn.microsoft.com/en-us/library/dd145102(VS.85).aspx
Modified:
trunk/reactos/dll/win32/user32/windows/paint.c
Modified: trunk/reactos/dll/win32/user32/windows/paint.c
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/user32/windows/p…
==============================================================================
--- trunk/reactos/dll/win32/user32/windows/paint.c [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/user32/windows/paint.c [iso-8859-1] Sat Jan 9 07:16:51 2010
@@ -149,7 +149,13 @@
Hook = BeginIfHookedUserApiHook();
/* Bypass SEH and go direct. */
- if (!Hook) return (int)NtUserSetWindowRgn(hWnd, hRgn, bRedraw);
+ if (!Hook)
+ {
+ Ret = NtUserSetWindowRgn(hWnd, hRgn, bRedraw);
+ if (hRgn && Ret)
+ DeleteObject(hRgn);
+ return Ret;
+ }
_SEH2_TRY
{