This is the mail archive of the
gdb-patches@sources.redhat.com
mailing list for the GDB project.
dejagnu hang from target.exp (prune_warnings)
- To: Nick Clifton <nickc at cygnus dot com>,Richard Earnshaw <rearnsha at arm dot com>
- Subject: dejagnu hang from target.exp (prune_warnings)
- From: Andrew Cagney <ac131313 at cygnus dot com>
- Date: Fri, 19 Jan 2001 18:47:44 +1100
- Cc: GDB Patches <gdb-patches at sourceware dot cygnus dot com>,SID Discussion <sid at sources dot redhat dot com>
The change:
< 2001-01-12 Richard Earnshaw <rearnsha@arm.com>
<
< * target.exp (prune_warnings): Prune warnings from NetBSD
linker.
<
checked in by NickC causes dejagnu to hang (or to at least take a very
very very very very long walk) when the compiler generates lots of
output. Looking at the patch:
- # Or the NetBSD ones.
- regsub -all "(^|\n)(.*:\[0-9\]+: warning: \[^\n\]* possibly used
unsafely, use \[^\n\]*\n?)" $text "\\1" text
- regsub -all "(^|\n)(.*: warning: reference to compatibility
glob\[^\n\]*\n?)" $text "\\1" text
that leading ``.*'' is just too generous :-(
The attatched stops the problem for me. Can someone please confirm this
doesn't break on NetBSD.
enjoy,
Andrew
Fri Jan 19 18:37:19 2001 Andrew Cagney <cagney@b1.cygnus.com>
* lib/target.exp (prune_warnings): Avoid ``.*'' in NetBSD warnings
pattern.
Index: lib/target.exp
===================================================================
RCS file: /cvs/src/src/dejagnu/lib/target.exp,v
retrieving revision 1.7
diff -p -r1.7 target.exp
*** target.exp 2001/01/12 18:13:40 1.7
--- target.exp 2001/01/19 07:39:47
*************** proc prune_warnings { text } {
*** 262,269 ****
regsub -all "(^|\n)(ld(|32|64): Giving up.*Use -wall\[^\n\]*\n?)+" $text "\\1" text
# Or the NetBSD ones.
! regsub -all "(^|\n)(.*:\[0-9\]+: warning: \[^\n\]* possibly used unsafely, use \[^\n\]*\n?)" $text "\\1" text
! regsub -all "(^|\n)(.*: warning: reference to compatibility glob\[^\n\]*\n?)" $text "\\1" text
# GNU ld warns about functions marked as dangerous in GNU libc.
regsub -all "(^|\n)\[^\n\]*: In function\[^\n\]*\n\[^\n\]\[^\n\]*function is dangerous\[^\n\]*" $text "" text
--- 262,269 ----
regsub -all "(^|\n)(ld(|32|64): Giving up.*Use -wall\[^\n\]*\n?)+" $text "\\1" text
# Or the NetBSD ones.
! regsub -all "(^|\n)(\[^\n\]*:\[0-9\]+: warning: \[^\n\]* possibly used unsafely, use \[^\n\]*\n?)" $text "\\1" text
! regsub -all "(^|\n)(\[^\n\]*: warning: reference to compatibility glob\[^\n\]*\n?)" $text "\\1" text
# GNU ld warns about functions marked as dangerous in GNU libc.
regsub -all "(^|\n)\[^\n\]*: In function\[^\n\]*\n\[^\n\]\[^\n\]*function is dangerous\[^\n\]*" $text "" text