Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: "Eli Zaretskii" <eliz@gnu.org>
To: gdb-patches@sources.redhat.com, Joel Brobecker <brobecker@adacore.com>
Subject: Re: [RFA] maintenance_print_msymbols: Try harder to match files
Date: Mon, 02 May 2005 19:20:00 -0000	[thread overview]
Message-ID: <01c54f4b$Blat.v2.4$cb9e0700@zahav.net.il> (raw)
In-Reply-To: <20050501233700.GD4311@nevyn.them.org> (message from Daniel Jacobowitz on Sun, 1 May 2005 19:37:00 -0400)

> Date: Sun, 1 May 2005 19:37:00 -0400
> From: Daniel Jacobowitz <drow@false.org>
> Cc: Joel Brobecker <brobecker@adacore.com>
> 
> You're comparing solely based on inode number; I think that's an unwise
> choice for two reasons:
>   - The file may have been replaced on disk; we should use the copy
>     that was there when GDB opened it.
>   - There are some file systems in which all st_ino values are zero.
> 
> If you've got the full path, why not use that?

Indeed.  symtab.c:lookup_symbol has an example of what I think you
should use (and what AFAIU Daniel had in mind).  Note that file-name
comparison should use FILENAME_CMP instead of strcmp, to avoid
failures on non-Posix systems.


  reply	other threads:[~2005-05-02 19:20 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-01-24 21:09 Corinna Vinschen
2005-05-01 23:37 ` Daniel Jacobowitz
2005-05-02 19:20   ` Eli Zaretskii [this message]
2005-05-02 19:46     ` Eli Zaretskii
2005-05-02 20:05   ` Joel Brobecker
2005-05-02 20:07     ` Daniel Jacobowitz
2005-05-02 20:18       ` Joel Brobecker

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='01c54f4b$Blat.v2.4$cb9e0700@zahav.net.il' \
    --to=eliz@gnu.org \
    --cc=brobecker@adacore.com \
    --cc=gdb-patches@sources.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