From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 29821 invoked by alias); 10 Feb 2014 18:18:14 -0000 Mailing-List: contact gdb-prs-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-prs-owner@sourceware.org Received: (qmail 29783 invoked by uid 48); 10 Feb 2014 18:18:14 -0000 From: "marc.khouzam at ericsson dot com" To: gdb-prs@sourceware.org Subject: [Bug breakpoints/16551] New: Execution stops when encountering a dprintf with an invalid string Date: Mon, 10 Feb 2014 18:18:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gdb X-Bugzilla-Component: breakpoints X-Bugzilla-Version: 7.7 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: marc.khouzam at ericsson dot com X-Bugzilla-Status: NEW X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: unassigned at sourceware dot org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Bugzilla-URL: http://sourceware.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2014-q1/txt/msg00157.txt.bz2 https://sourceware.org/bugzilla/show_bug.cgi?id=16551 Bug ID: 16551 Summary: Execution stops when encountering a dprintf with an invalid string Product: gdb Version: 7.7 Status: NEW Severity: normal Priority: P2 Component: breakpoints Assignee: unassigned at sourceware dot org Reporter: marc.khouzam at ericsson dot com I define a dprintf that has an error in its printout function (as the user may do this by mistake). When the dprintf is hit, an error printout is output and the execution stops. However, no *stopped event is issued. This missing *stopped event is not good, but I think the problem to fix is that the execution should not stop in this case. If a user sets a dprintf, she expects the execution to continue and there may be negative consequence at suddenly stopping the execution. Addressing bug 15185 would probably fix this. Here is a stripped session that shows how to reproduce: > gdb -i mi loopfirst =thread-group-added,id="i1" ~"GNU gdb (GDB) 7.7\n" ~"Reading symbols from loopfirst..." ~"done.\n" (gdb) dprintf 5,"%d\n",badvariable (gdb) i b &"i b\n" ~"Num Type Disp Enb Address What\n" ~"1 dprintf keep y 0x000000000040054c in main() at loopfirst.cc:5\n" ~" printf \"%d\\n\",badvariable\n" ^done (gdb) 22-exec-run =thread-group-started,id="i1",pid="13398" =thread-created,id="1",group-id="i1" 22^running *running,thread-id="all" (gdb) 22^error,msg="No symbol \"badvariable\" in current context." (gdb) i thre &"i thre\n" ~" Id Target Id Frame \n" ~"* 1 process 13398 \"loopfirst\" main () at loopfirst.cc:5\n" ^done === Notice that the thread is stopped although we did an -exec-run == -- You are receiving this mail because: You are on the CC list for the bug.