Source-Changes-D archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: CVS commit: src/lib/librumphijack
On Wed, Feb 09, 2011 at 02:30:38AM +0000, Christos Zoulas wrote:
> >To get the layering correct, we could make the fortification code define
> >another prototype and use double rename, e.g.
> >
> >ssize_t __real_read(int __fd, ...) __RENAME(read);
> >
> >__ssp_inline ssize_t read(int __fd, ...) __RENAME(__ssp_read);
> >
> >__sso_inline ssize_t read(int __fd, ...) {
> > __ssp_check(__buf, __lean, bos);
> > return __real_read(__fd, ...);
> >}
>
> Yes, that would work. An extra level of indirection always works.
It isn't really. It is just tricking the compiler into creating the
right external symbols. The result is that using SSP doesn't change
which symbols end up being called.
Joerg
Home |
Main Index |
Thread Index |
Old Index