diff options
Diffstat (limited to 'fs/ubifs/super.c')
-rw-r--r-- | fs/ubifs/super.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/fs/ubifs/super.c b/fs/ubifs/super.c index 63b2164..26b48f0 100644 --- a/fs/ubifs/super.c +++ b/fs/ubifs/super.c @@ -848,8 +848,10 @@ void ubifs_umount(struct ubifs_info *c) ubifs_debugging_exit(c); /* Finally free U-Boot's global copy of superblock */ - free(ubifs_sb->s_fs_info); - free(ubifs_sb); + if (ubifs_sb != NULL) { + free(ubifs_sb->s_fs_info); + free(ubifs_sb); + } } /** |