This is the mail archive of the
gdb-patches@sourceware.cygnus.com
mailing list for the GDB project.
[patch/sim/common] Fix uninitialized sigrc variable
- To: GDB Patches <gdb-patches at sourceware dot cygnus dot com>
- Subject: [patch/sim/common] Fix uninitialized sigrc variable
- From: Andrew Cagney <ac131313 at cygnus dot com>
- Date: Tue, 23 May 2000 21:33:06 +1000
- Organization: Cygnus Solutions
Just FYI,
Andrew
Tue May 23 20:30:12 2000 Andrew Cagney <cagney@amy.cygnus.com>
* run.c (main): Initialize sigrc.
Index: run.c
===================================================================
RCS file: /cvs/src/src/sim/common/run.c,v
retrieving revision 1.4
diff -p -r1.4 run.c
*** run.c 2000/02/22 08:52:20 1.4
--- run.c 2000/05/23 11:31:53
*************** main (ac, av)
*** 242,247 ****
--- 242,248 ----
sim_stop_reason() can be used to determine any stop reason. */
if (trace)
sim_set_trace ();
+ sigrc = 0;
do
{
prev_sigint = signal (SIGINT, cntrl_c);
*************** main (ac, av)
*** 265,270 ****
--- 266,272 ----
else
{
prev_sigint = signal (SIGINT, cntrl_c);
+ sigrc = 0;
sim_resume (sd, 0, sigrc);
signal (SIGINT, prev_sigint);
sim_stop_reason (sd, &reason, &sigrc);