diff options
author | maxim <maxim@FreeBSD.org> | 2006-09-30 07:34:20 +0000 |
---|---|---|
committer | maxim <maxim@FreeBSD.org> | 2006-09-30 07:34:20 +0000 |
commit | 9e9ac4a6cb141480fa6d92ead1afe93bbcd387ac (patch) | |
tree | 1504a9bb853052388c861131284aae1abe107a7c /usr.sbin | |
parent | cbd0a8935f0630f3bc951a220e62ee0b4fbbab01 (diff) | |
download | FreeBSD-src-9e9ac4a6cb141480fa6d92ead1afe93bbcd387ac.zip FreeBSD-src-9e9ac4a6cb141480fa6d92ead1afe93bbcd387ac.tar.gz |
o Check we have a non-NULL pointer to a super block before dereference it.
PR: misc/103822
Submitted by: Dmitry Stefankov
MFC after: 2 weeks
Diffstat (limited to 'usr.sbin')
-rw-r--r-- | usr.sbin/quot/quot.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/usr.sbin/quot/quot.c b/usr.sbin/quot/quot.c index 7ef4ae8..84892b0 100644 --- a/usr.sbin/quot/quot.c +++ b/usr.sbin/quot/quot.c @@ -121,7 +121,7 @@ get_inode(fd,super,ino) if (ipbuf) { free(ipbuf); ipbuf = 0; - if (super->fs_magic == FS_UFS2_MAGIC) { + if (super != NULL && super->fs_magic == FS_UFS2_MAGIC) { free(cgp); cgp = 0; } |