Invalid filesystem might cause the bp to be never read.

Noted by:	Pedro F. Giffuni <giffunip tutopia com>
Obtanined from:	NetBSD
MFC after:	1 week
This commit is contained in:
Konstantin Belousov 2010-02-14 12:10:49 +00:00
parent 8310a1a27a
commit 3c8b687fe1
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=203866

View File

@ -944,7 +944,8 @@ fillinusemap(pmp)
if (readcn == 0)
usemap_free(pmp, cn);
}
brelse(bp);
if (bp != NULL)
brelse(bp);
return (0);
}