Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ODS2 should not depend on RMS EOF attribute in INDEXF.SYS #19

Open
al20878 opened this issue Nov 14, 2024 · 0 comments
Open

ODS2 should not depend on RMS EOF attribute in INDEXF.SYS #19

al20878 opened this issue Nov 14, 2024 · 0 comments

Comments

@al20878
Copy link
Contributor

al20878 commented Nov 14, 2024

It looks like in old systems, the EOF attribute of INDEXF.SYS wasn't properly updated (yet the map area properly described all extents).

As a result, file IDs beyond the (stale) EOF block would be flagged as "Not in index file" by access.c (built with -DDEBUG):

15,1,0, 0 Not in index file
Accessfile fail status 00000910

That would result in

FILE.EXT;1         %SYSTEM-W-NOSUCHFILE, no such file

showing in the directory listing (instead of e.g. size and/or date).

Removing the offending condition, like so:

    if (vcbdev->idxfcb->head != NULL) {
#if 0
        if (idxblk >=
            F11SWAP(vcbdev->idxfcb->head->fh2$w_recattr.fat$l_efblk)) {
#if DEBUG
            printf("%u,%u,%u, %u Not in index file\n",
                   fid->fid$w_num, fid->fid$w_seq, fid->fid$b_rvn, fid->fid$b_nmx);
#endif
            return SS$_NOSUCHFILE;
        }
#endif
    }

allowed to process all files successfully.

The ODS-2 documentation says that all file header blocks in INDEXF.SYS should be considered depending on their contents, and no other conditions. If a block passes the validity checks (well-known fields, including the checksum) it is a valid file header (even regardless of the INDEXF.SYS-own header bitmap). EOF is an RMS attribute, which is the next level up in the file structure.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant