Re: Syslets, Threadlets, generic AIO support, v6

From: Davide Libenzi
Date: Wed May 30 2007 - 15:41:18 EST


On Wed, 30 May 2007, Ingo Molnar wrote:

> yeah - this is a fundamental design question for Linus i guess :-) glibc
> (and other infrastructure libraries) have a fundamental problem: they
> cannot (and do not) presently use persistent file descriptors to make
> use of kernel functionality, due to ABI side-effects. [applications can
> dup into an fd used by glibc, applications can close it - shells close
> fds blindly for example, etc.] Today glibc simply cannot open a file
> descriptor and keep it open while application code is running due to
> these problems.

Here I think we are forgetting that glibc is userspace and there's no
separation between the application code and glibc code. An application
linking to glibc can break glibc in thousand ways, indipendently from fds
or not fds. Like complaining that glibc is broken because printf()
suddendly does not work anymore ;)

#include <stdio.h>
int main(void) {
close(fileno(stdout));
printf("Whiskey Tango Foxtrot?\n");
return 0;
}



- Davide


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/