diff options
author | rwatson <rwatson@FreeBSD.org> | 2000-10-06 15:31:28 +0000 |
---|---|---|
committer | rwatson <rwatson@FreeBSD.org> | 2000-10-06 15:31:28 +0000 |
commit | 8d202cd4d055cb16038e4ab876d444ab8a29bca4 (patch) | |
tree | bcc661392e0432018c016dc56dff7b4a4d959001 /sys | |
parent | 4cb303d852708523da37ff72998d6099af8bdeba (diff) | |
download | FreeBSD-src-8d202cd4d055cb16038e4ab876d444ab8a29bca4.zip FreeBSD-src-8d202cd4d055cb16038e4ab876d444ab8a29bca4.tar.gz |
o Move initialization of ump from mp to the top of the function so that
it is defined whenm used in ufs_extattr_uepm_destroy(), fixing a panic
due to a NULL pointer dereference.
Submitted by: Wesley Morgan <morganw@chemicals.tacorp.com>
Diffstat (limited to 'sys')
-rw-r--r-- | sys/ufs/ffs/ffs_vfsops.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/sys/ufs/ffs/ffs_vfsops.c b/sys/ufs/ffs/ffs_vfsops.c index 48cf93d..41e0786 100644 --- a/sys/ufs/ffs/ffs_vfsops.c +++ b/sys/ufs/ffs/ffs_vfsops.c @@ -772,7 +772,7 @@ ffs_unmount(mp, mntflags, p) int mntflags; struct proc *p; { - register struct ufsmount *ump; + register struct ufsmount *ump = VFSTOUFS(mp); register struct fs *fs; int error, flags; @@ -794,7 +794,6 @@ ffs_unmount(mp, mntflags, p) if ((error = ffs_flushfiles(mp, flags, p)) != 0) return (error); } - ump = VFSTOUFS(mp); fs = ump->um_fs; if (fs->fs_ronly == 0) { fs->fs_clean = fs->fs_flags & FS_UNCLEAN ? 0 : 1; |