This is the mail archive of the gdb@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: find_and_open_source bug?


>>>>> "Doug" == Doug Evans <dje@google.com> writes:

Doug> If find_and_open_source opens the file via rewrite_source_path,
Doug> should xfullname get called?
Doug> Grep for XXX below.

Doug> Seems so, otherwise the caller can't really assume what's
Doug> stored in *fullname is a "fullpath" (as defined by xfullpath).
Doug> [Maybe rewritten source paths shouldn't get passed through xfullpath
Doug> but then why does the rest of the function do that?]

Doug> [I'm trying to understand what invariants callers of find_and_open_source
Doug> can expect.]

Probably nobody has ever tried to do something weird here.

I think it would be safe for you to pick an approach that preserves
whatever sensible user scenarios there are.  E.g., require that path
substitutions map full paths to full paths or something like that.

Tom


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