+2007-08-24 Corinna Vinschen <corinna@vinschen.de>
+
+ * syscalls.cc (open): Don't follow symlinks if O_EXCL is given.
+
2007-08-23 Corinna Vinschen <corinna@vinschen.de>
* ntdll.h (STATUS_NO_SUCH_FILE): Define.
if (fd >= 0)
{
- if (!(fh = build_fh_name (unix_path, NULL, (flags & O_NOFOLLOW) ?
- PC_SYM_NOFOLLOW : PC_SYM_FOLLOW,
+ if (!(fh = build_fh_name (unix_path, NULL,
+ (flags & (O_NOFOLLOW | O_EXCL))
+ ? PC_SYM_NOFOLLOW : PC_SYM_FOLLOW,
transparent_exe ? stat_suffixes : NULL)))
res = -1; // errno already set
else if ((flags & O_NOFOLLOW) && fh->issymlink ())