- To: GDB Patches <gdb-patches at sourceware dot cygnus dot com>
- Subject: [rfa] inflow.c - initialize local variable osigttou
- From: Andrew Cagney <ac131313 at cygnus dot com>
- Date: Mon, 27 Nov 2000 18:49:17 +1100
Hello,
The attatched cleans up a -Wuninitialized and (I think) a potential
-Wunused-local warning.
Ok?
Andrew
Mon Nov 20 13:59:29 2000 Andrew Cagney <cagney@b1.cygnus.com>
* inflow.c (terminal_ours_1): Initialize ``osigtou''. Only
declare when have SIGTTOU.
Index: inflow.c
===================================================================
RCS file: /cvs/src/src/gdb/inflow.c,v
retrieving revision 1.3
diff -p -r1.3 inflow.c
*** inflow.c 2000/07/30 01:48:25 1.3
--- inflow.c 2000/11/27 06:54:03
*************** terminal_ours_1 (int output_only)
*** 318,326 ****
if (!terminal_is_ours)
{
/* Ignore this signal since it will happen when we try to set the
pgrp. */
! void (*osigttou) ();
int result;
terminal_is_ours = 1;
--- 318,328 ----
if (!terminal_is_ours)
{
+ #ifdef SIGTTOU
/* Ignore this signal since it will happen when we try to set the
pgrp. */
! void (*osigttou) () = NULL;
! #endif
int result;
terminal_is_ours = 1;