* fhandler_disk_file.cc (fhandler_disk_file::readdir): Fix inode number

evaluation for faked "." entry.

	* mount.cc (fs_info::update): Move setting of is_cdrom after checking
	for caseinsensitivity.  Recognize UDF in is_cdrom case and set
	caseinsensitive flag according to UDF brokenness determined by OS.
	Add comment to explain why.
	* mount.h (class fs_info): Add is_udf status flag.
	* path.cc (symlink_info::check): Add workaround for UDF bug in
	terms of casesensitivity on certain OSes.
	* wincap.h (wincaps::has_broken_udf): New element.
	(wincaps::has_broken_udf): New element
This commit is contained in:
Corinna Vinschen
2009-01-29 20:32:08 +00:00
parent bacd5877ba
commit 43616e5526
7 changed files with 73 additions and 3 deletions

View File

@@ -262,7 +262,6 @@ fs_info::update (PUNICODE_STRING upath, HANDLE in_vol)
}
is_ntfs (RtlEqualUnicodeString (&fsname, &testname, FALSE)
&& !is_samba () && !is_netapp ());
is_cdrom (ffdi.DeviceType == FILE_DEVICE_CD_ROM);
has_acls (flags () & FS_PERSISTENT_ACLS);
hasgood_inode (((flags () & FILE_PERSISTENT_ACLS) && !is_netapp ())
@@ -274,6 +273,21 @@ fs_info::update (PUNICODE_STRING upath, HANDLE in_vol)
caseinsensitive ((!(flags () & FILE_CASE_SENSITIVE_SEARCH) || is_samba ())
&& !is_nfs ());
is_cdrom (ffdi.DeviceType == FILE_DEVICE_CD_ROM);
if (is_cdrom ())
{
RtlInitUnicodeString (&testname, L"UDF");
is_udf (RtlEqualUnicodeString (&fsname, &testname, FALSE));
/* UDF on NT 5.x is broken (at least) in terms of case sensitivity. The
UDF driver reports the FILE_CASE_SENSITIVE_SEARCH capability but:
- Opening the root directory for query seems to work at first, but the
filenames in the directory listing are mutilated.
- When trying to open a file or directory case sensitive, the file
appears to be non-existant. */
if (is_udf () && wincap.has_broken_udf ())
caseinsensitive (true);
}
if (!in_vol)
NtClose (vol);
return true;