diff options
author | phk <phk@FreeBSD.org> | 1995-03-28 07:46:38 +0000 |
---|---|---|
committer | phk <phk@FreeBSD.org> | 1995-03-28 07:46:38 +0000 |
commit | 6ad7636d4a24ed5873a051888c579f5ef47677c4 (patch) | |
tree | 2fc37a19460c14445fdef5c9eba433b6cb6b6fce /sys/isofs | |
parent | 61b9c158a406e0c4f450b97eab6832a89f03d469 (diff) | |
download | FreeBSD-src-6ad7636d4a24ed5873a051888c579f5ef47677c4.zip FreeBSD-src-6ad7636d4a24ed5873a051888c579f5ef47677c4.tar.gz |
Readdir on a CDrom would return bogus "d_type" values, potentially confusing
everybody (incl find(1) ?). Initialize it to DT_UNKNOWN. Maybe we can
do better, but I don't have the time.
Diffstat (limited to 'sys/isofs')
-rw-r--r-- | sys/isofs/cd9660/cd9660_vnops.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/sys/isofs/cd9660/cd9660_vnops.c b/sys/isofs/cd9660/cd9660_vnops.c index cddfed0..5e403e3 100644 --- a/sys/isofs/cd9660/cd9660_vnops.c +++ b/sys/isofs/cd9660/cd9660_vnops.c @@ -36,7 +36,7 @@ * SUCH DAMAGE. * * @(#)cd9660_vnops.c 8.3 (Berkeley) 1/23/94 - * $Id: cd9660_vnops.c,v 1.11 1995/01/16 17:03:28 joerg Exp $ + * $Id: cd9660_vnops.c,v 1.12 1995/02/13 06:12:32 phk Exp $ */ #include <sys/param.h> @@ -557,6 +557,9 @@ cd9660_readdir(ap) break; } + /* XXX: be more intelligent if we can */ + idp->current.d_type = DT_UNKNOWN; + idp->current.d_namlen = isonum_711 (ep->name_len); if (isoflags & 2) isodirino(&idp->current.d_fileno,ep,imp); |