Article View: comp.windows.x
Article #24826Re: How does one debug a server using dbx/gdb?
From: Mike Hoegeman
Date: Tue, 12 Jan 1993 06:31
Date: Tue, 12 Jan 1993 06:31
16 lines
1433 bytes
1433 bytes
In article <7326@ucsbcsl.ucsb.edu> doug@foxtrot.ccmrc.ucsb.edu (Douglas Scott) writes: >Is there a special trick to debug an X server binary using gdb or dbx? That >is, how can you start it up and have the debugger be able to follow the >progress from the beginning, given that the server is normally started via >xinit? I know that I can start it normally and then attach to the process, >but how would I debug it from the very beginning? You can do something cheesy like in main() put a a call to pause() or select() if some magic environment variable is set. Then the server will just sit there in the pause and you can attach to it at your leasure. once you are attached just do something that will cause pause to return like ^C. -- ------------------------------------------------------------------------------ Mike Hoegeman email: mh@wx.gtegsc.com tel: (818)706-4145 GTE Weather Systems Group 31717 La Tienda Dr, Westlake Village CA. 91359
Technical Details
Message-ID:
<1993Jan12.063159.14863@awds.imsd.contel.com>Path:
arc1-ca.pugleaf.net!sparky!uunet!zaphod.mps.ohio-state.edu!howland.reston.ans.net!europa.asd.contel.com!awds.imsd.contel.com!mhReferences:
<7326@ucsbcsl.ucsb.edu>Show Full Headers
Complete Article Headers
Newsgroups: comp.windows.x Path: arc1-ca.pugleaf.net!sparky!uunet!zaphod.mps.ohio-state.edu!howland.reston.ans.net!europa.asd.contel.com!awds.imsd.contel.com!mh From: mh@awds.imsd.contel.com (Mike Hoegeman) Subject: Re: How does one debug a server using dbx/gdb? Message-ID: <1993Jan12.063159.14863@awds.imsd.contel.com> Organization: GTE Weather Systems, Westlake Village, CA References: <7326@ucsbcsl.ucsb.edu> Date: Tue, 12 Jan 1993 06:31:59 GMT Lines: 16