This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc 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: fopen() calls __open()


Ulrich Drepper <drepper@redhat.com> writes:

> Derrell.Lipman@UnwiredUniverse.com wrote:
>> What can I do to cause fopen() in glibc to call the open() or _open() or
>> __open() in the preload instead of the internal __open?
>
> Nothing.  Once a call enters glibc it won't leave it until it's down.
> Exceptions: the malloc functions.  Everything is completely opaque and
> that won't change.

Ok.  Thanks for the response.

I'm a bit confused as to why certain functions are weak and allowed to be
overridden (e.g. open, __open) but not higher-level functions that use them.
It seems a bit inconsistent, but I assume there's a reason.  If there's some
prior thread that explains this, I'd sure appreciate a pointer to it.
Otherwise, might you be able to explain why primitives can be overridden but
not such that the users of those primitives within the library use the
overridden versions?

Thanks!

Derrell


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