From: Tom G. <to...@li...> - 2001-08-22 21:43:29
|
* Tom Gilbert (to...@li...) wrote: > Then I take an image created (and previously rendered) using the old > display, and rendering it to a drawable created in the new display. This > actually works fine. I then close that X connection, pop and free the ^^^^^^^^^^^^^^^^^^^^^^^ > 460 if (disp != d) > 461 { > 462 if (gc) XFreeGC(disp, gc); ^^^^ Oh, dumb of me I didn't see that. So it's an imlib2 bug. The problem is I don't know how to fix it. You're keeping the last used display in a static variable, but of course you have no way of knowing that it's been closed (a perfectly valid situation), and that call cores, because you can't use a close()d display (the memory has been cleaned up - the GC is _already_ free()d). So what should we do? I know you don't want to recreate the GC on each call, but is there another way? Tom. -- .^. .-------------------------------------------------------. /V\ | Tom Gilbert, London, England | http://linuxbrit.co.uk | /( )\ | Open Source/UNIX consultant | to...@li... | ^^-^^ `-------------------------------------------------------' |