detecting the X-server crash

This is a discussion on detecting the X-server crash within the Xwindows forums, part of the Tools category; Hello, Is it possible to detect the X-server crash from within the program? I would like to detect that case, so I can restart X...

Go Back   Unix Linux Forum > Technologies & Tools > Tools > Xwindows

FixUnix.com - Unix Linux Forums

Unix Content Register FAQ Calendar Search Today's Posts Mark Forums Read
  #1  
Old 09-30-2008, 04:17 AM
Default detecting the X-server crash

Hello,

Is it possible to detect the X-server crash from within the program?

I would like to detect that case, so I can restart X
Reply With Quote
  #2  
Old 09-30-2008, 06:37 AM
Default Re: detecting the X-server crash

anon wrote:
> Hello,
>
> Is it possible to detect the X-server crash from within the program?
>
> I would like to detect that case, so I can restart X


If you run you system with a GUI login screen like GDM or KDM, then that
is handled for you. For example: Using GDM I log into my system and see
the Gnome desktop. I press Ctrl+Alt+Backspace which kills the X-server,
but the X-server auto restarts and shows me the GUI login again.


Regards,
- Graeme -

__________________________________________________ _____
fpGUI - a cross-platform GUI toolkit using Free Pascal
http://opensoft.homeip.net/fpgui/

Reply With Quote
  #3  
Old 09-30-2008, 10:41 AM
Default Re: detecting the X-server crash

Graeme Geldenhuys wrote:
> anon wrote:
>> Hello,
>>
>> Is it possible to detect the X-server crash from within the program?
>>
>> I would like to detect that case, so I can restart X

>
> If you run you system with a GUI login screen like GDM or KDM, then that
> is handled for you. For example: Using GDM I log into my system and see
> the Gnome desktop. I press Ctrl+Alt+Backspace which kills the X-server,
> but the X-server auto restarts and shows me the GUI login again.


Thank you for responding, but that doesn't answer my question. Maybe it
was not clean enough.

Lets say I have a c++ program, which displays a window with two embedded
opengl windows. Now, from within this program I want to detect a "x
server crashed" state and restart it (again from the program). Is this
possible?
Reply With Quote
Reply

Thread Tools


All times are GMT -5. The time now is 12:33 AM.

In an effort to better serve ads to our visitors, cookies are used on Fixunix.com. For more information, check out our Privacy Policy.

Powered by vBulletin® Version 3.7.2
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0
Ad Management by RedTyger