Re: [AD] Problem with remove_mouse() and video bitmaps. |
[ Thread Index |
Date Index
| More lists.liballeg.org/allegro-developers Archives
]
- To: alleg-developers@xxxxxxxxxx
- Subject: Re: [AD] Problem with remove_mouse() and video bitmaps.
- From: Chris <chris.kcat@xxxxxxxxxx>
- Date: Wed, 28 Dec 2005 15:24:11 -0800
- Domainkey-signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:from:to:subject:date:user-agent:references:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:message-id; b=XxKIFB4WO3UWpRtHqwJoeAujZGpdEoPPXEp1TAUpHNOyHux/ZzCm3B/L1FaAttxE1o0Iv5SG5AHT7kfb14UNb64M/9OJt0IUAED4lu0rq57Z47u18UQXNHacHyQGC8l3CAEJZj75jcdis9vIlTWOw9E5oo5tPySnLtwwQqXAbOk=
On Wednesday 28 December 2005 14:33, Andrei Ellman wrote:
> I've noticed that if I set the mouse to display on a bitmap created with
> create_video_bitmap(), then if I destroy the video bitmap and call
> remove_mouse(), I can sometimes cause a crash or get my app to pause
> before restoring the desktop resolution.
Because the timer runs asyncronously, the mouse update function can be called
after the bitmap is destroyed, but before the mouse is removed. In such a
case, the timer function would try to read from/write to an invalid memory
address.