Re: gdb.mi/mi-cli.exp failures

Ian Lance Taylor
2003-04-01T01:38:45Z

Hans-Peter Nilsson <hp@bitrange.com> writes:

> On Mon, 31 Mar 2003, Andrew Cagney wrote:
> > And this:
> >
> > > - return concat (filename);
> > > + return filename;
> >
> > (remembering that the patch is backwards) doesn't look so good. It
> > should be:
> >
> > concat (filename, NULL);
> >
> > perhaps
> >
> > xstrdup (filename)
> >
> > would be easier to read :-)
>
> \begin{chant} There must be no xstrdup calls in bfd. BFD must
> not abort; it's a library and the caller must handle allocation
> failures. There may be xstrdup calls in bfd already, but please
> don't add new ones. \end{chant}

Could use strdup, though, not that I know the context here.

Ian