projects
/
platform
/
upstream
/
f2fs-tools.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
bbc4176
)
fsck.f2fs: nullify raw_super pointer
author
Jaegeuk Kim
<jaegeuk@kernel.org>
Thu, 21 Jan 2016 01:13:14 +0000
(09:13 +0800)
committer
Jaegeuk Kim
<jaegeuk@kernel.org>
Thu, 21 Jan 2016 13:13:56 +0000
(21:13 +0800)
Otherwise it will cause double free.
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
fsck/mount.c
patch
|
blob
|
history
diff --git
a/fsck/mount.c
b/fsck/mount.c
index
c4dfb0a
..
4c807f9
100644
(file)
--- a/
fsck/mount.c
+++ b/
fsck/mount.c
@@
-339,6
+339,7
@@
int validate_super_block(struct f2fs_sb_info *sbi, int block)
}
free(sbi->raw_super);
+ sbi->raw_super = NULL;
MSG(0, "\tCan't find a valid F2FS superblock at 0x%x\n", block);
return -EINVAL;