Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Stan Shebs <stanshebs@earthlink.net>
To: gdb-patches@sourceware.org
Subject: Re: "maint print arch" causing gdb crash
Date: Fri, 05 Oct 2012 22:05:00 -0000	[thread overview]
Message-ID: <506F599E.5080903@earthlink.net> (raw)
In-Reply-To: <506EEAEC.2010604@codesourcery.com>

On 10/5/12 7:13 AM, ali_anwar wrote:
> Hi,
>
> 'gdbarch_dump' is in some cases passing a NULL pointer to 'sprintf' 
> when printing 'gdbarch->stap_gdb_register_suffix' etc.  Printing NULL 
> pointers like this is undefined behavior. With glibc passing a NULL 
> pointer just prints "(null)". With the MSVC libc, however, GDB crashes.
>
> Attached patch fixes this issue using the similar approach discussed 
> in following scenario:
> http://sourceware.org/ml/gdb-patches/2011-10/msg00662.html
>
> There are some newly added variables due to which "maint print arch" 
> command was causing gdb crash on whindows host. This patch takes care 
> of them.
>
> OK?

Yes please, this is good!

Stan
stan@codesourcery.com


  reply	other threads:[~2012-10-05 22:05 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-10-05 14:15 ali_anwar
2012-10-05 22:05 ` Stan Shebs [this message]
2012-10-07  9:07 ` Yao Qi
2012-10-08 11:47   ` ali_anwar
2012-10-08 13:12     ` Yao Qi

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=506F599E.5080903@earthlink.net \
    --to=stanshebs@earthlink.net \
    --cc=gdb-patches@sourceware.org \
    /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