C and C++ SoftBench User's Guide
Using SoftBench Debugger
Interacting with Your Program
Chapter 7176
that interactions between SoftBench Debugger and your program do not
lead to a deadlock. Events are processed when they happen, and are
directed to the appropriate window. Debugging X programs not running
in synchronous mode can lead to deadlock situations in which the
keyboard focus is on an unresponsive window.
The XtAppInitialize function called to initialize the X Toolkit can set
your application to synchronous mode. Do one of the following:
• Pass the -synchronize argument to your program on the command
line. To always pass this argument to your X program, add
-synchronize to the default argument listusing "Options: Default
Load/Rerun Settings…".
• Use the synchronize resource. You can specify it using xrdb, or in
your $HOME/.Xdefaults file:
[
Application
*synchronize: on]
where
Application
is the class name of your program.
Your program has full control while it executes under SoftBench
Debugger. Mouse functions and keyboard events pass to your program as
usual, with the keyboard focus controlled by the X Window System
and your window manager. When your program reaches a breakpoint,
SoftBench Debugger regains control.
Your program's input and output work as they normally do. If you have
not redirected stdin, stdout,orstderr, they refer to the User Program
I/O Area.
In some situations it may be necessary to display the program being
debugged on a different display terminal. You can do this by specifying
the DISPLAY environment variable in the "File: Load Executable"
dialog before you execute the program.