On Wed, Aug 17, 2011 at 03:13:09PM +0200, Denys Vlasenko wrote: > > This means that the programs you start from the command line, inheriting the > > shell's stdin/out/err can influence them, and by extension, influence all > > further programs to be launched. > > Yes, this is a bug in Unix API. Nonblocking I/O should have been done > more sanely. Socket I/O has MSG_DONTWAIT flag which is *per-syscall*, > but ordinary read/write don't, and have to mess with file flags,
This is by design and part of how multi-tool script programming works. > Please, ping LKML and ask them whether Linux is going to fix this mess. > (The more people nag developers about it, the higher are chances they'll > do something). My proposal was to make recv/send work on ordinary file > fd's too, and allow MSG_DONTWAIT flag to be used in this case. Ordinary file IO never blocks. If there's a delay, it's a sleep not a block, and it's the same as the delay from swapping. If you need to ensure realtime performance there are already correct ways to do it like mmapping the file and mlocking the map. After that, normal IO on the file should not be able to sleep. There's no sense in introducing more hideous non-portable Linux-specific ways to do things that can already be achieved. Rich _______________________________________________ busybox mailing list [email protected] http://lists.busybox.net/mailman/listinfo/busybox
