summaryrefslogtreecommitdiff
path: root/ufs/hyper.c
diff options
context:
space:
mode:
authorMichael I. Bushnell <mib@gnu.org>1994-07-14 19:50:21 +0000
committerMichael I. Bushnell <mib@gnu.org>1994-07-14 19:50:21 +0000
commitdb9c0b1e3ddf5399f7d6b730d74d52e58f260f49 (patch)
treef30296e29c0b802a176a28001b745a76c5ba7637 /ufs/hyper.c
parent8e541d5daec8ca840e90e65cb478b925eb1321ea (diff)
Formerly hyper.c.~6~
Diffstat (limited to 'ufs/hyper.c')
-rw-r--r--ufs/hyper.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/ufs/hyper.c b/ufs/hyper.c
index 7bb8d7c8..c9ffcc63 100644
--- a/ufs/hyper.c
+++ b/ufs/hyper.c
@@ -47,6 +47,13 @@ get_hypermetadata (void)
exit (1);
}
+ if (sblock->fs_maxsymlinklen > MAXSYMLINKLEN)
+ {
+ fprintf (stderr, "Max shortcut symlinklen %d is too big (max is %d)\n",
+ sblock->fs_maxsymlinklen, MAXSYMLINKLEN);
+ exit (1);
+ }
+
/* If this is an old filesystem, then we have some more
work to do; some crucial constants might not be set; we
are therefore forced to set them here. */
@@ -57,6 +64,12 @@ get_hypermetadata (void)
if (sblock->fs_postblformat == FS_42POSTBLFMT)
sblock->fs_nrpos = 8;
+ /* Find out if we support the 4.4 symlink/dirtype extension */
+ if (sblock->fs_maxsymlinklen > 0)
+ direct_symlink_extension = 1;
+ else
+ direct_symlink_extension = 0;
+
err = dev_read_sync (fsbtodb (sblock->fs_csaddr), (vm_address_t *) &csum,
sblock->fs_fsize * howmany (sblock->fs_cssize,
sblock->fs_fsize));