mirror of
https://github.com/FDOS/kernel.git
synced 2025-07-30 01:04:31 +02:00
Fix problem with an old game that calls findfirst with attribute 77a8:
the kernel should not return a volume label in that case. git-svn-id: https://svn.code.sf.net/p/freedos/svn/kernel/trunk@1322 6ac86273-5f31-0410-b378-82cca8765d1b
This commit is contained in:
parent
ea91fd0236
commit
4a8c30c6e2
@ -383,9 +383,15 @@ COUNT dos_findfirst(UCOUNT attr, BYTE * name)
|
|||||||
/* Special handling - the volume id is only in the root */
|
/* Special handling - the volume id is only in the root */
|
||||||
/* directory and only searched for once. So we need to open */
|
/* directory and only searched for once. So we need to open */
|
||||||
/* the root and return only the first entry that contains the */
|
/* the root and return only the first entry that contains the */
|
||||||
/* volume id bit set. */
|
/* volume id bit set (while ignoring LFN entries). */
|
||||||
if ((attr & (D_VOLID|D_DIR))==D_VOLID)
|
/* RBIL: ignore ReaDONLY and ARCHIVE bits */
|
||||||
i = 3;
|
/* For compatibility with bad search requests, only treat as */
|
||||||
|
/* volume search if only volume bit set, else ignore it. */
|
||||||
|
if ((attr & ~(D_RDONLY | D_ARCHIVE))==D_VOLID) /* if ONLY label wanted */
|
||||||
|
i = 3; /* redirect search to root dir (?) in volume label case */
|
||||||
|
else
|
||||||
|
attr &= ~D_VOLID; /* ignore volume mask */
|
||||||
|
|
||||||
/* Now open this directory so that we can read the */
|
/* Now open this directory so that we can read the */
|
||||||
/* fnode entry and do a match on it. */
|
/* fnode entry and do a match on it. */
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user