This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RE: Better realpath


I just looked at your patch and the idea seems
good... But I am no expert on this field.

  One question though, libiberty lrealpath
function uses strdup, while the replaced 
code uses xstrdup.
  xstrdup is also defined in libiberty
as being a replacement of strdup that never
fails... (didn't really get how this is
possible...)

  Anyhow, is this a potential issue?


Pierre Muller
Pascal language support maintainer for GDB



-----Message d'origine-----
De : gdb-patches-owner@sourceware.org [mailto:gdb-patches-owner@sourceware.org] De la part de Vladimir Prus
Envoyà : Saturday, June 14, 2008 8:25 AM
à : gdb-patches@sources.redhat.com
Objet : Better realpath


GDB has a function to get real path of a file, gdb_realpath. Unfortunately, that function is essentially a copy-paste of libiberty's lrealpath, with the extra bonus that gdb_realpath *does not* have any Windows-specific code. As result, GDB is not capable to simplify ".." in windows paths, and among other problems, breakpoints set using full file names containing ".." will not work.

This patch makes GDB use libibery's lrealpath. OK?

- Volodya

       gdb/
       * utils.c (gdb_realpath): Use lrealpath.



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]