[PATCH] Free metadata superblock after ext2 metadata has been commited.
Matt Davis
mattdavis9 at gmail.com
Fri May 2 04:03:53 UTC 2008
Deallocate memory allocated after it has been used to store sb data. This occurs when writing ext2 metadata to disk.
---
libparted/fs/ext2/ext2.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/libparted/fs/ext2/ext2.c b/libparted/fs/ext2/ext2.c
index 79fc6f6..121cf9c 100644
--- a/libparted/fs/ext2/ext2.c
+++ b/libparted/fs/ext2/ext2.c
@@ -657,6 +657,8 @@ int ext2_commit_metadata(struct ext2_fs *fs, int copies)
/* Clear the flags of the components we just finished writing. */
fs->metadirty &= ~copies;
+ ped_free (sb);
+
return 1;
}
--
1.5.1.5
--/04w6evG8XlLl3ft--
More information about the parted-devel
mailing list