I've written a small program using the gtk2hs library and it crashes at unpredictable times with X windows errors like the one below.  I looked for the messages online and found various people talking about buggy gtk libraries but no clear solutions.  I don't know a lot about X windows or what these errors mean.  Has anyone else had this problem or know what to do?  The program is a simple implementation of the Conway Life game.  It doesn't have very much going on except that the main window is an animation showing the evolution of the game.  I tried running with the --sync option as it said and you get an almost immediate error like "Xlib: unexpected async reply (sequence 0x1652)!".  Even these are not predictable and often come after several screen updates.  I'm using the Gtk.timeoutAddFull function to do the animation.  Note that the error_code, request_code, etc.. changes with each crash.  It's as though it picks a
 random error code each time.&nbsp; I've compiled with both ghc 6.4.2 and 6.6.1 and gtk2hs 0.9.12 and 0.9.12.1.&nbsp; I've tried various combinations of -O flags as well.&nbsp; Same problem every time.<br><br><br><br>A typical crash message<br>-----------------------------------------------------------------------<br>The program 'hlh' received an X Window System error.<br>This probably reflects a bug in the program.<br>The error was 'BadDrawable (invalid Pixmap or Window parameter)'.<br>&nbsp; (Details: serial 236321 error_code 9 request_code 62 minor_code 0)<br>&nbsp; (Note to programmers: normally, X errors are reported asynchronously;<br>&nbsp;&nbsp; that is, you will receive the error a while after causing it.<br>&nbsp;&nbsp; To debug your program, run it with the --sync command line<br>&nbsp;&nbsp; option to change this behavior. You can then get a meaningful<br>&nbsp;&nbsp; backtrace from your debugger if you break on the gdk_x_error() function.)<br>  <p>&#32;

      <hr size=1>Never miss a thing.  <a href="http://us.rd.yahoo.com/evt=51438/*http://www.yahoo.com/r/hs"> Make Yahoo your homepage.</a>