diff options
author | Dmitrij Tejblum <dt@FreeBSD.org> | 1999-01-02 18:52:13 +0000 |
---|---|---|
committer | Dmitrij Tejblum <dt@FreeBSD.org> | 1999-01-02 18:52:13 +0000 |
commit | 57081f7b944d5d1c6fce6ad94db7e79b5bfe3d81 (patch) | |
tree | 8fa59ca2fb08690bbf3b8bce282d5d11c5d4a847 /sys/fs | |
parent | 28cb15a9a9f17eb6b5ca98294d560e14cbfc8d09 (diff) | |
download | src-57081f7b944d5d1c6fce6ad94db7e79b5bfe3d81.tar.gz src-57081f7b944d5d1c6fce6ad94db7e79b5bfe3d81.zip |
Now empty DOS filesystems default to long file names. Non-empty filesystems
without traces of Win95 default to short file names, as before.
Notes
Notes:
svn path=/head/; revision=42252
Diffstat (limited to 'sys/fs')
-rw-r--r-- | sys/fs/msdosfs/msdosfs_lookup.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/sys/fs/msdosfs/msdosfs_lookup.c b/sys/fs/msdosfs/msdosfs_lookup.c index 9323cd5d5913..87de1f23eba3 100644 --- a/sys/fs/msdosfs/msdosfs_lookup.c +++ b/sys/fs/msdosfs/msdosfs_lookup.c @@ -1,4 +1,4 @@ -/* $Id: msdosfs_lookup.c,v 1.26 1998/09/13 15:40:31 dt Exp $ */ +/* $Id: msdosfs_lookup.c,v 1.27 1998/12/07 21:58:35 archie Exp $ */ /* $NetBSD: msdosfs_lookup.c,v 1.37 1997/11/17 15:36:54 ws Exp $ */ /*- @@ -1040,21 +1040,22 @@ findwin95(dep) { struct msdosfsmount *pmp = dep->de_pmp; struct direntry *dentp; - int blsize; + int blsize, win95; u_long cn; daddr_t bn; struct buf *bp; + win95 = 1; /* * Read through the directory looking for Win'95 entries * Note: Error currently handled just as EOF XXX */ for (cn = 0;; cn++) { if (pcbmap(dep, cn, &bn, 0, &blsize)) - return 0; + return (win95); if (bread(pmp->pm_devvp, bn, blsize, NOCRED, &bp)) { brelse(bp); - return 0; + return (win95); } for (dentp = (struct direntry *)bp->b_data; (char *)dentp < bp->b_data + blsize; @@ -1064,7 +1065,7 @@ findwin95(dep) * Last used entry and not found */ brelse(bp); - return 0; + return (win95); } if (dentp->deName[0] == SLOT_DELETED) { /* @@ -1077,6 +1078,7 @@ findwin95(dep) brelse(bp); return 1; } + win95 = 0; } brelse(bp); } |