If you execute mkdir version 4.0x with stdout closed it creates the directory, writes an error message to stderr, and exits with status 1. POSIX-2 says that the standard output shall not be written when the utility is used as described by POSIX-2, so it should not matter whether it is closed or open.
To demonstrate this: $ mkdir xyz 1>&- mkdir: write error: Bad file descriptor $ echo $? 1 $ rmdir xyz I discovered this when running a very old program that, for reasons of portability, creates a directory by forking, closing stdin, stdout and stderr, execing "mkdir", and testing the exit status. It believes that mkdir has failed. Jan Kasprzak has a patch which claims to address this issue at ftp://ftp.linux.cz/pub/users/kas/fileutils/fileutils-4.0-closed-stdout.p atch but it does not appear to be included in fileutils-4.1. Jon Hitchcock Uniplex Ltd, 126 Hempstead Road, Kings Langley, Herts, WD4 8AL E-mail [EMAIL PROTECTED], Tel +44 (0) 1923 299718, Fax 299701 _______________________________________________ Bug-fileutils mailing list [EMAIL PROTECTED] http://mail.gnu.org/mailman/listinfo/bug-fileutils