English version
Accueil     À propos     Téléchargement     Ressources     Contactez-nous    

Ce site est rarement mis à jour. Pour les informations les plus récentes, rendez-vous sur le nouveau site OCaml à l'adresse ocaml.org.

Browse thread
[Caml-list] lablgtk question: catching server shutdown
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2002-02-05 (10:37)
From: Hendrik Tews <tews@t...>
Subject: [Caml-list] lablgtk question: catching server shutdown

I have a lablgtk question:

Is there a canonical way to register a function that will be
called when the connection to the X server is lost?

I looked at the gtk sources (version 1.2.9) and there they
register the function gdk_x_io_error with XSetIOErrorHandler. And
gdk_x_io_error prints 

  Gdk-ERROR **: X connection to :0.0 broken (explicit kill or server shutdown).

and calls exit. So it looks like there is no way to register a
callback for this event. Am I right?

How do others do "cleaning up" when the X server dies?


Bug reports: http://caml.inria.fr/bin/caml-bugs  FAQ: http://caml.inria.fr/FAQ/
To unsubscribe, mail caml-list-request@inria.fr  Archives: http://caml.inria.fr