From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 14521 invoked by alias); 31 Jan 2005 16:43:01 -0000 Mailing-List: contact gdb-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sources.redhat.com Received: (qmail 14201 invoked from network); 31 Jan 2005 16:42:46 -0000 Received: from unknown (HELO lakermmtao10.cox.net) (68.230.240.29) by sourceware.org with SMTP; 31 Jan 2005 16:42:46 -0000 Received: from white ([68.9.64.121]) by lakermmtao10.cox.net (InterMail vM.6.01.04.00 201-2131-117-20041022) with ESMTP id <20050131164246.COKG15803.lakermmtao10.cox.net@white> for ; Mon, 31 Jan 2005 11:42:46 -0500 Received: from bob by white with local (Exim 3.35 #1 (Debian)) id 1CvedS-000281-00 for ; Mon, 31 Jan 2005 11:42:46 -0500 Date: Mon, 31 Jan 2005 16:43:00 -0000 From: Bob Rossi To: GDB Subject: MI testsuite problem Message-ID: <20050131164246.GB7955@white> Mail-Followup-To: GDB Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.3.28i X-SW-Source: 2005-01/txt/msg00162.txt.bz2 Hi, I Think I've found a problem in the MI testsuite. Basically, I've run runtest with debug mode on for the mi2-basic.exp testcase. This gives me the log file which I'm pretty sure shows the problem. The -break-list command is matching the regular expression in mi-support.exp:mi_gdb_test, which is -re "(\[\r\n\]*(($pattern)\[\r\n\]+$mi_gdb_prompt\[ \]*$))" The problem is, the matching string has a leading '201-break-list' that should not be there. If you run GDB standalone the output is not there. I think this is a bug that could mask some problems in the MI testsuite. Does anyone know how this could be happening? It appears as if Expect is matching the 'send' command in the results. I don't think Expect does this, but I don't know how else the 'send' command could end up in the output command. Does anyone else? Please look at the result below. In particular the 'set expect_out' is what Expect is saying it matched. Thanks, Bob Rossi send: sending "201-break-list\n" to { exp11 } expect: does "" (spawn_id exp11) match regular expression "\*\*\* DOSEXIT code.*"? no "Ending remote debugging.*[(]gdb[)] \r\n[ ]*$"? no "([\r\n]*((.*\^done,BreakpointTable=\{.*,body=\[\]\})[\r\n]+[(]gdb[)] \r\n[ ]*$))"? no "(^FOOBAR$)$"? no "Undefined.* command:.*[(]gdb[)] \r\n[ ]*$"? no "Ambiguous command.*[(]gdb[)] \r\n[ ]*$"? no "Program exited with code [0-9]+.*[(]gdb[)] \r\n[ ]*$"? no "The program is not being run.*[(]gdb[)] \r\n[ ]*$"? no ".*[(]gdb[)] \r\n[ ]*$"? no ""? no "\(y or n\) "? no full_buffer? no 201-break-list expect: does "201-break-list\r\n" (spawn_id exp11) match regular expression "\*\*\* DOSEXIT code.*"? no "Ending remote debugging.*[(]gdb[)] \r\n[ ]*$"? no "([\r\n]*((.*\^done,BreakpointTable=\{.*,body=\[\]\})[\r\n]+[(]gdb[)] \r\n[ ]*$))"? no "(^FOOBAR$)$"? no "Undefined.* command:.*[(]gdb[)] \r\n[ ]*$"? no "Ambiguous command.*[(]gdb[)] \r\n[ ]*$"? no "Program exited with code [0-9]+.*[(]gdb[)] \r\n[ ]*$"? no "The program is not being run.*[(]gdb[)] \r\n[ ]*$"? no ".*[(]gdb[)] \r\n[ ]*$"? no ""? no "\(y or n\) "? no full_buffer? no 201^done,BreakpointTable={nr_rows="0",nr_cols="6",hdr=[{width="3",alignment="-1",col_name="number",colhdr="Num"},{width="14",alignment="-1",col_name="type",colhdr="Type"},{width="4",alignment="-1",col_name="disp",colhdr="Disp"},{width="3",alignment="-1",col_name="enabled",colhdr="Enb"},{width="10",alignment="-1",col_name="addr",colhdr="Address"},{width="40",alignment="2",col_name="what",colhdr="What"}],body=[]} expect: does "201-break-list\r\n201^done,BreakpointTable={nr_rows="0",nr_cols="6",hdr=[{width="3",alignment="-1",col_name="number",colhdr="Num"},{width="14",alignment="-1",col_name="type",colhdr="Type"},{width="4",alignment="-1",col_name="disp",colhdr="Disp"},{width="3",alignment="-1",col_name="enabled",colhdr="Enb"},{width="10",alignment="-1",col_name="addr",colhdr="Address"},{width="40",alignment="2",col_name="what",colhdr="What"}],body=[]}\r\n" (spawn_id exp11) match regular expression "\*\*\* DOSEXIT code.*"? no "Ending remote debugging.*[(]gdb[)] \r\n[ ]*$"? no "([\r\n]*((.*\^done,BreakpointTable=\{.*,body=\[\]\})[\r\n]+[(]gdb[)] \r\n[ ]*$))"? no "(^FOOBAR$)$"? no "Undefined.* command:.*[(]gdb[)] \r\n[ ]*$"? no "Ambiguous command.*[(]gdb[)] \r\n[ ]*$"? no "Program exited with code [0-9]+.*[(]gdb[)] \r\n[ ]*$"? no "The program is not being run.*[(]gdb[)] \r\n[ ]*$"? no ".*[(]gdb[)] \r\n[ ]*$"? no ""? no "\(y or n\) "? no full_buffer? no (gdb) expect: does "201-break-list\r\n201^done,BreakpointTable={nr_rows="0",nr_cols="6",hdr=[{width="3",alignment="-1",col_name="number",colhdr="Num"},{width="14",alignment="-1",col_name="type",colhdr="Type"},{width="4",alignment="-1",col_name="disp",colhdr="Disp"},{width="3",alignment="-1",col_name="enabled",colhdr="Enb"},{width="10",alignment="-1",col_name="addr",colhdr="Address"},{width="40",alignment="2",col_name="what",colhdr="What"}],body=[]}\r\n(gdb) \r\n" (spawn_id exp11) match regular expression "\*\*\* DOSEXIT code.*"? no "Ending remote debugging.*[(]gdb[)] \r\n[ ]*$"? no "([\r\n]*((.*\^done,BreakpointTable=\{.*,body=\[\]\})[\r\n]+[(]gdb[)] \r\n[ ]*$))"? yes expect: set expect_out(0,string) "201-break-list\r\n201^done,BreakpointTable={nr_rows="0",nr_cols="6",hdr=[{width="3",alignment="-1",col_name="number",colhdr="Num"},{width="14",alignment="-1",col_name="type",colhdr="Type"},{width="4",alignment="-1",col_name="disp",colhdr="Disp"},{width="3",alignment="-1",col_name="enabled",colhdr="Enb"},{width="10",alignment="-1",col_name="addr",colhdr="Address"},{width="40",alignment="2",col_name="what",colhdr="What"}],body=[]}\r\n(gdb) \r\n" expect: set expect_out(1,string) "201-break-list\r\n201^done,BreakpointTable={nr_rows="0",nr_cols="6",hdr=[{width="3",alignment="-1",col_name="number",colhdr="Num"},{width="14",alignment="-1",col_name="type",colhdr="Type"},{width="4",alignment="-1",col_name="disp",colhdr="Disp"},{width="3",alignment="-1",col_name="enabled",colhdr="Enb"},{width="10",alignment="-1",col_name="addr",colhdr="Address"},{width="40",alignment="2",col_name="what",colhdr="What"}],body=[]}\r\n(gdb) \r\n" expect: set expect_out(2,string) "201-break-list\r\n201^done,BreakpointTable={nr_rows="0",nr_cols="6",hdr=[{width="3",alignment="-1",col_name="number",colhdr="Num"},{width="14",alignment="-1",col_name="type",colhdr="Type"},{width="4",alignment="-1",col_name="disp",colhdr="Disp"},{width="3",alignment="-1",col_name="enabled",colhdr="Enb"},{width="10",alignment="-1",col_name="addr",colhdr="Address"},{width="40",alignment="2",col_name="what",colhdr="What"}],body=[]}\r\n(gdb) \r\n" expect: set expect_out(3,string) "201-break-list\r\n201^done,BreakpointTable={nr_rows="0",nr_cols="6",hdr=[{width="3",alignment="-1",col_name="number",colhdr="Num"},{width="14",alignment="-1",col_name="type",colhdr="Type"},{width="4",alignment="-1",col_name="disp",colhdr="Disp"},{width="3",alignment="-1",col_name="enabled",colhdr="Enb"},{width="10",alignment="-1",col_name="addr",colhdr="Address"},{width="40",alignment="2",col_name="what",colhdr="What"}],body=[]}" expect: set expect_out(spawn_id) "exp11" expect: set expect_out(buffer) "201-break-list\r\n201^done,BreakpointTable={nr_rows="0",nr_cols="6",hdr=[{width="3",alignment="-1",col_name="number",colhdr="Num"},{width="14",alignment="-1",col_name="type",colhdr="Type"},{width="4",alignment="-1",col_name="disp",colhdr="Disp"},{width="3",alignment="-1",col_name="enabled",colhdr="Enb"},{width="10",alignment="-1",col_name="addr",colhdr="Address"},{width="40",alignment="2",col_name="what",colhdr="What"}],body=[]}\r\n(gdb) \r\n"