Check value returned by g_read_data(9), otherwise we can end in panic(9)
if read error happens. MFC after: 1 week
This commit is contained in:
parent
2207c7648e
commit
5c8a6f63b2
@ -74,6 +74,9 @@ g_label_ntfs_taste(struct g_consumer *cp, char *label, size_t size)
|
||||
goto done;
|
||||
|
||||
filerecp = g_read_data(cp, voloff, recsize, &error);
|
||||
if (filerecp == NULL)
|
||||
goto done;
|
||||
|
||||
fr = (struct filerec *)filerecp;
|
||||
|
||||
if(fr->fr_fixup.fh_magic != NTFS_FILEMAGIC){
|
||||
|
Loading…
Reference in New Issue
Block a user