From: Andrew Cagney <ac131313@redhat.com>
To: Michael Snyder <msnyder@redhat.com>
Cc: gdb@sources.redhat.com
Subject: Re: set prompt-escape-character
Date: Tue, 05 Aug 2003 19:52:00 -0000 [thread overview]
Message-ID: <3F300B01.8050803@redhat.com> (raw)
In-Reply-To: <3F3004B9.2040003@redhat.com>
> Andrew Cagney wrote:
>
> More -Wformat-nonliteral suprizes. In trying to understand the "top.c" warnings from:
>
> /* FIXME: how to protect GDB from crashing
> from bad user-supplied format string? */
> sprintf (outp, fmt[0] == 0 ? default_fmt : fmt,
> tmp);
>
> I discovered a new feature:
>
> (top-gdb) set prompt-escape-char 0x25
> (top-gdb) set prompt PC=0x%0x%$pc
> PC=0x1802f68
>
> Perhaps it could be change do use the printf code vis:
> set prompt "0x%x ", $pc
>
> Anyway, Michael, was there any doco on this? I can't find anything.
>
> No, I think I was hoping no one would use it. ;-)
> This was something that a customer forced us to add, back in the
> "bad old days" when there wasn't much review over gdb. I really really tried to talk them out of it, honest.
Stan Shebs was always threatening to delete the undocumented commands
;-) Perhaps this should be silently dropped.
Andrew
prev parent reply other threads:[~2003-08-05 19:52 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-08-05 3:54 Andrew Cagney
2003-08-05 19:25 ` Michael Snyder
2003-08-05 19:52 ` Andrew Cagney [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=3F300B01.8050803@redhat.com \
--to=ac131313@redhat.com \
--cc=gdb@sources.redhat.com \
--cc=msnyder@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).