Re: [RFA] Assuming malloc exists in callfwmall.exp

Andrew Cagney
2001-02-15T10:34:00Z

> > As far as I can tell, the proposed change defeats this test. Yes, there
> > are targets that really don't have malloc() and on those targets the
> > test should probably xfailed. However, on any target with a shared
> > library() I think it should be allowed to run.
> >
>
> But then it is equivalent to callfuncs.exp, which has already run.

It is subtly different.

callfuncs.exp has an explictly linked malloc and the malloc
run-time-link is forced (using the next over the malloc() call).
callfwamll doesn't have the explicit malloc and doesn't force final
linkage of malloc(). GDB when it goes to call malloc() indirectly is
forcing that linkage indirectly.

Subtle I know. I suspect the test as it currently stands is over kill
though.

Andrew