* Minor typo in frame.c debug printing
@ 2003-07-02 17:44 Nick Kelsey
2003-07-02 19:14 ` Andrew Cagney
0 siblings, 1 reply; 2+ messages in thread
From: Nick Kelsey @ 2003-07-02 17:44 UTC (permalink / raw)
To: gdb
Hi guys,
There is a minor typo in frame_register_unwind line 549 -
--- frame.c 26 Jun 2003 02:15:22 -0000 1.1.1.2
+++ frame.c 2 Jul 2003 17:41:22 -0000
@@ -543,13 +543,13 @@
fprintf_unfiltered (gdb_stdlog, " *bufferp=");
if (bufferp == NULL)
fprintf_unfiltered (gdb_stdlog, "<NULL>");
else
{
int i;
- const char *buf = bufferp;
+ const unsigned char *buf = bufferp;
fprintf_unfiltered (gdb_stdlog, "[");
for (i = 0; i < register_size (current_gdbarch, regnum); i++)
fprintf_unfiltered (gdb_stdlog, "%02x", buf[i]);
fprintf_unfiltered (gdb_stdlog, "]");
}
fprintf_unfiltered (gdb_stdlog, " }\n");
Otherwise when the char gets promoted to an int it may get sign-extended
(depending on the host architecture).
Nick
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: Minor typo in frame.c debug printing
2003-07-02 17:44 Minor typo in frame.c debug printing Nick Kelsey
@ 2003-07-02 19:14 ` Andrew Cagney
0 siblings, 0 replies; 2+ messages in thread
From: Andrew Cagney @ 2003-07-02 19:14 UTC (permalink / raw)
To: Nick Kelsey; +Cc: gdb
> Hi guys,
>
> There is a minor typo in frame_register_unwind line 549 -
>
> --- frame.c 26 Jun 2003 02:15:22 -0000 1.1.1.2
> +++ frame.c 2 Jul 2003 17:41:22 -0000
> @@ -543,13 +543,13 @@
> fprintf_unfiltered (gdb_stdlog, " *bufferp=");
> if (bufferp == NULL)
> fprintf_unfiltered (gdb_stdlog, "<NULL>");
> else
> {
> int i;
> - const char *buf = bufferp;
> + const unsigned char *buf = bufferp;
> fprintf_unfiltered (gdb_stdlog, "[");
> for (i = 0; i < register_size (current_gdbarch, regnum); i++)
> fprintf_unfiltered (gdb_stdlog, "%02x", buf[i]);
> fprintf_unfiltered (gdb_stdlog, "]");
> }
> fprintf_unfiltered (gdb_stdlog, " }\n");
>
> Otherwise when the char gets promoted to an int it may get sign-extended
> (depending on the host architecture).
Are your sources up-to-date? I thought I just fixed this.
Andrew
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2003-07-02 19:14 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-07-02 17:44 Minor typo in frame.c debug printing Nick Kelsey
2003-07-02 19:14 ` Andrew Cagney
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).