diff options
author | Keith Packard <keithp@keithp.com> | 2010-04-30 12:18:09 -0700 |
---|---|---|
committer | Keith Packard <keithp@keithp.com> | 2010-05-03 10:26:52 -0700 |
commit | cdeb2c23f80ced961fe205125547e16905885534 (patch) | |
tree | 87d4690c2b0a01580d7675e6b56d563512002995 /hw/xfree86/ramdac | |
parent | a80b1f888f2f7674a715d512ab950eeadee20448 (diff) |
Fix cursor ref counting mistakes with sprites and xf86Cursor.c
A few cursor value assignments weren't getting correctly ref counted,
causing leaks of cursor objects.
Reviewed-by: Adam Jackson <ajax@redhat.com>
Signed-off-by: Keith Packard <keithp@keithp.com>
Diffstat (limited to 'hw/xfree86/ramdac')
-rw-r--r-- | hw/xfree86/ramdac/xf86Cursor.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/hw/xfree86/ramdac/xf86Cursor.c b/hw/xfree86/ramdac/xf86Cursor.c index f5f087314..346e99490 100644 --- a/hw/xfree86/ramdac/xf86Cursor.c +++ b/hw/xfree86/ramdac/xf86Cursor.c @@ -312,6 +312,8 @@ xf86CursorSetCursor(DeviceIntPtr pDev, ScreenPtr pScreen, CursorPtr pCurs, xf86SetCursor(pScreen, NullCursor, x, y); ScreenPriv->isUp = FALSE; } + if (ScreenPriv->CurrentCursor) + FreeCursor(ScreenPriv->CurrentCursor, None); ScreenPriv->CurrentCursor = NullCursor; return; } |