This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RFA: gdb.base/charset.exp: don't use expect_out without regexp groups


This looks like a cut-and-paste mistake to me.  There's nothing in the
regexp for $expect_out to be referring to, so (in my case) this would
grab random text produced by callfuncs.exp and treat it as a host
charset name.

2004-06-03  Jim Blandy  <jimb@redhat.com>

	* gdb.base/charset.exp: Don't refer to $expect_out(1,string) in
	cases where the regexp has no groups; this grabs random text from
	the previous test suite, whatever that was.  Remove commented-out
	code.

Index: gdb/testsuite/gdb.base/charset.exp
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/gdb.base/charset.exp,v
retrieving revision 1.3
diff -c -p -r1.3 charset.exp
*** gdb/testsuite/gdb.base/charset.exp	26 Feb 2004 17:23:23 -0000	1.3
--- gdb/testsuite/gdb.base/charset.exp	4 Jun 2004 04:30:40 -0000
*************** gdb_expect {
*** 200,206 ****
  
      -re "\\.\r\n$gdb_prompt $" {
  	#set host_charset_list $expect_out(1,string)
- 	set charsets($expect_out(1,string)) 1
  	pass "capture valid host charsets"
      }
  
--- 200,205 ----


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]