diff options
author | joerg <joerg@FreeBSD.org> | 1995-01-16 17:03:29 +0000 |
---|---|---|
committer | joerg <joerg@FreeBSD.org> | 1995-01-16 17:03:29 +0000 |
commit | 21c4534499755e8a9532c806a9000f7b82f3b02d (patch) | |
tree | def197b76a0dbb2e02ce9cadbaf5ba6564e42704 /sys/isofs/cd9660/cd9660_lookup.c | |
parent | cd232c506dc892f127bbf3eb3bdb5a0f241536bd (diff) | |
download | FreeBSD-src-21c4534499755e8a9532c806a9000f7b82f3b02d.zip FreeBSD-src-21c4534499755e8a9532c806a9000f7b82f3b02d.tar.gz |
Roll in my changes to make the cd9660 code understand the older
(original "High Sierra") CD format. I've already implemented this for
1.1.5.1 (and posted to -hackers), but didn't get any response to it.
Perhaps i'm the only one who has such an old CD lying around...
Everything is done empirically, but i had three of them around (from
different vendors), so there's a high probability that i've got it
right. :)
Diffstat (limited to 'sys/isofs/cd9660/cd9660_lookup.c')
-rw-r--r-- | sys/isofs/cd9660/cd9660_lookup.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/sys/isofs/cd9660/cd9660_lookup.c b/sys/isofs/cd9660/cd9660_lookup.c index 800a9da..9ae15f6 100644 --- a/sys/isofs/cd9660/cd9660_lookup.c +++ b/sys/isofs/cd9660/cd9660_lookup.c @@ -38,7 +38,7 @@ * from: @(#)ufs_lookup.c 7.33 (Berkeley) 5/19/91 * * @(#)cd9660_lookup.c 8.2 (Berkeley) 1/23/94 - * $Id: cd9660_lookup.c,v 1.4 1994/09/15 19:45:58 bde Exp $ + * $Id: cd9660_lookup.c,v 1.5 1994/09/26 00:32:54 gpalmer Exp $ */ #include <sys/param.h> @@ -116,6 +116,7 @@ cd9660_lookup(ap) ino_t ino = 0; int reclen; u_short namelen; + int isoflags; char altname[NAME_MAX]; int res; int assoc, len; @@ -276,6 +277,8 @@ searchloop: * Check for a name match. */ namelen = isonum_711(ep->name_len); + isoflags = isonum_711(imp->iso_ftype == ISO_FTYPE_HIGH_SIERRA? + &ep->date[6]: ep->flags); if (reclen < ISO_DIRECTORY_RECORD_SIZE + namelen) /* illegal entry, stop */ @@ -283,7 +286,7 @@ searchloop: switch (imp->iso_ftype) { default: - if ((!(isonum_711(ep->flags)&4)) == !assoc) { + if (!(isoflags & 4) == !assoc) { if ((len == 1 && *name == '.') || (flags & ISDOTDOT)) { @@ -302,7 +305,7 @@ searchloop: goto notfound; } else if (!(res = isofncmp(name,len, ep->name,namelen))) { - if (isonum_711(ep->flags)&2) + if (isoflags & 2) isodirino(&ino,ep,imp); else ino = dbtob(bp->b_blkno) |