diff --git a/reactos/subsys/win32k/objects/cursoricon.c b/reactos/subsys/win32k/objects/cursoricon.c index df86112bbbc..5052df6e66a 100644 --- a/reactos/subsys/win32k/objects/cursoricon.c +++ b/reactos/subsys/win32k/objects/cursoricon.c @@ -16,7 +16,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ -/* $Id: cursoricon.c,v 1.34 2003/12/10 22:09:56 weiden Exp $ */ +/* $Id: cursoricon.c,v 1.35 2003/12/10 22:47:11 weiden Exp $ */ #undef WIN32_LEAN_AND_MEAN @@ -306,6 +306,12 @@ IntDestroyCurIconObject(PWINSTATION_OBJECT WinStaObject, HANDLE Handle) return FALSE; } + if(WinStaObject->SystemCursor.CurrentCursorObject == Object) + { + ObmDereferenceObject(Object); + return FALSE; + } + bmpMask = Object->IconInfo.hbmMask; bmpColor = Object->IconInfo.hbmColor;