linux emu - support O_DIRECTORY for open syscall
authorAlex Hornung <ahornung@gmail.com>
Fri, 9 Apr 2010 06:49:06 +0000 (06:49 +0000)
committerAlex Hornung <ahornung@gmail.com>
Fri, 9 Apr 2010 07:39:57 +0000 (07:39 +0000)
commit9ea7e8bc214c6e4b865b9b70b34fb1f9e14ceae4
treef5c002fcb9dced0b6f96d663444c2f37f7e499a6
parent2c872e05abde7665fd7d24427d1317995fe97d2f
linux emu - support O_DIRECTORY for open syscall

* Linux opendir seems to rely on O_DIRECTORY to avoid certain race
  conditions, so introduce O_DIRECTORY support which just returns
  ENOTDIR even if the open is successful, if the opened path is not a
  directory.

* This fixes Ant's directory scanner.

Submitted-by: Johannes Hofmann
sys/emulation/linux/i386/linux.h
sys/emulation/linux/linux_file.c