Re: -file-list-exec-source-files

Bob Rossi
2004-06-28T19:48:07Z

On Sun, Jun 27, 2004 at 08:06:13PM +0200, Andreas Schwab wrote:
> Bob Rossi <bob@brasko.net> writes:
>
> > +/* Finds the fullname that a symtab represents.
> > +
> > + If this functions finds the fullname, it will save it in ps->fullname
> > + and it will also return the value.
> >
> > + If this function fails to find the file that this symtab represents,
> > + NULL will be returned and ps->fullname will be set to NULL. */
>
> This causes gdb to crash in lookup_symtab.
>
> if (full_path != NULL)
> {
> const char *fp = symtab_to_fullname (s);
> if (FILENAME_CMP (full_path, fp) == 0)
> {
> return s;
> }
> }
>
> if (real_path != NULL)
> {
> char *rp = gdb_realpath (symtab_to_fullname (s));
> make_cleanup (xfree, rp);
> if (FILENAME_CMP (real_path, rp) == 0)
> {
> return s;
> }
> }
>
> Neither of these places expect symtab_to_fullname to return NULL.

I will have a simple patch for this within the next few hours.

Thanks,
Bob Rossi