public inbox for gdb-prs@sourceware.org
help / color / mirror / Atom feed
* Re: breakpoints/2120: "info break" output not good when cond is a function call with string arg
@ 2008-07-26 22:49 tromey
0 siblings, 0 replies; 4+ messages in thread
From: tromey @ 2008-07-26 22:49 UTC (permalink / raw)
To: gdb-prs, nobody, rgulati
Synopsis: "info break" output not good when cond is a function call with string arg
State-Changed-From-To: open->closed
State-Changed-By: tromey
State-Changed-When: Sat Jul 26 22:49:56 2008
State-Changed-Why:
I tried this using the F8 gdb (based on 6.6).
It worked fine for me, so I think this bug has been fixed.
Thanks.
http://sourceware.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gdb&pr=2120
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: breakpoints/2120: "info break" output not good when cond is a function call with string arg
@ 2008-03-10 21:08 Tom Tromey
0 siblings, 0 replies; 4+ messages in thread
From: Tom Tromey @ 2008-03-10 21:08 UTC (permalink / raw)
To: nobody; +Cc: gdb-prs
The following reply was made to PR breakpoints/2120; it has been noted by GNATS.
From: Tom Tromey <tromey@redhat.com>
To: gdb-gnats@sources.redhat.com, nobody@sources.redhat.com,
rgulati@cadence.com, gdb-prs@sources.redhat.com
Cc:
Subject: Re: breakpoints/2120: "info break" output not good when cond is a function call with string arg
Date: Mon, 10 Mar 2008 14:12:03 -0600
I tried this and I saw the same problem.
Could you resend your patch in unidiff or context diff format to the
gdb-patches list? That is the best way to get it reviewed. Thanks.
Tom
^ permalink raw reply [flat|nested] 4+ messages in thread
* RE: breakpoints/2120: "info break" output not good when cond is a function call with string arg
@ 2006-04-28 20:58 Rohit Gulati
0 siblings, 0 replies; 4+ messages in thread
From: Rohit Gulati @ 2006-04-28 20:58 UTC (permalink / raw)
To: nobody; +Cc: gdb-prs
The following reply was made to PR breakpoints/2120; it has been noted by GNATS.
From: "Rohit Gulati" <rgulati@cadence.com>
To: <gdb-gnats@sources.redhat.com>, <nobody@sources.redhat.com>
Cc:
Subject: RE: breakpoints/2120: "info break" output not good when cond is a function call with string arg
Date: Fri, 28 Apr 2006 13:53:59 -0700
Hi,
I debugged the problem reported in GDB bug breakpoints/2120 and have a
fix. I changed the file src/expprint.c, function print_subexp_standard,
switch case OP_ARRAY:
Please review the change and let me know if it is ok:
file 1 .../gdb/src/gdb-6.3/gdb/expprint.c
********************************
-----[242-243 changed to 242-245]-----
< && exp->elts[pc + 5].type =3D=3D builtin_type_char
< && exp->language_defn->la_language =3D=3D language_c
---
> /*&& exp->elts[pc + 5].type =3D=3D builtin_type_char*/
> && exp->elts[pc + 5].type =3D=3D builtin_type
(current_gdbarch)->builtin_char
> && (exp->language_defn->la_language =3D=3D language_c ||=20
> exp->language_defn->la_language =3D=3D language_cplus) )
-----[257 changed to 259-260]-----
< || exp->elts[pc + 1].type !=3D builtin_type_char)
---
> /*|| exp->elts[pc + 1].type !=3D builtin_type_char*/
> || exp->elts[pc + 1].type !=3D builtin_type
(current_gdbarch)->builtin_char)
>-----Original Message-----
>From: gdb-gnats@sources.redhat.com=20
>[mailto:gdb-gnats@sources.redhat.com]=20
>Sent: Wednesday, April 26, 2006 4:48 PM
>To: Rohit Gulati
>Subject: Re: breakpoints/2120: "info break" output not good=20
>when cond is a function call with string arg
>
>Thank you very much for your problem report.
>It has the internal identification `breakpoints/2120'.
>The individual assigned to look at your
>report is: unassigned.=20
>
>>Category: breakpoints
>>Responsible: unassigned
>>Synopsis: "info break" output not good when cond is a=20
>function call with string arg
>>Arrival-Date: Wed Apr 26 23:48:01 GMT 2006
>
^ permalink raw reply [flat|nested] 4+ messages in thread
* breakpoints/2120: "info break" output not good when cond is a function call with string arg
@ 2006-04-26 23:48 rgulati
0 siblings, 0 replies; 4+ messages in thread
From: rgulati @ 2006-04-26 23:48 UTC (permalink / raw)
To: gdb-gnats
>Number: 2120
>Category: breakpoints
>Synopsis: "info break" output not good when cond is a function call with string arg
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: unassigned
>State: open
>Class: change-request
>Submitter-Id: net
>Arrival-Date: Wed Apr 26 23:48:01 GMT 2006
>Closed-Date:
>Last-Modified:
>Originator: rgulati@cadence.com
>Release: GDB 6.3
>Organization:
>Environment:
Red Hat Enterprise Linux WS release 3 (Taroon Update 5)
GCC 3.2.3
>Description:
If you create a conditional breakpoint on a function call, which takes one string argument, like:
(gdb) break test.cpp:1 if (foo("Rohit"))
(gdb) info break
Then "info break" prints the output in which the argument to the function, foo above, get printed as a comma separated ASCII values instead of the string itself:
What gets printed is :
....
stop only if foo ( {82 'R', 111 'o', 104 'h', 105 'i', 116 't', 0 '\0'})
I was expecting:
stop only if foo("Rohit")
thanks
Rohit
>How-To-Repeat:
To reproduce:
1. Create the following testcase in test.cpp:
bool foo(char* xxx) {return true;}
int main() {foo("Rohit");return 0;}
2. Compile "g++ -g test.cpp"
3. Start "gdb a.out"
4. Type these gdb commands:
(gdb)break test.cpp:1 if (foo("Rohit"))
(gdb)info break
>Fix:
>Release-Note:
>Audit-Trail:
>Unformatted:
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2008-07-26 22:49 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-07-26 22:49 breakpoints/2120: "info break" output not good when cond is a function call with string arg tromey
-- strict thread matches above, loose matches on Subject: below --
2008-03-10 21:08 Tom Tromey
2006-04-28 20:58 Rohit Gulati
2006-04-26 23:48 rgulati
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).