From: yury Date: Fri, 13 May 2005 10:09:47 +0000 (+0000) Subject: fixes possible memory leak on error case path X-Git-Tag: 1.4.10~1163 X-Git-Url: https://git.whamcloud.com/gitweb?a=commitdiff_plain;h=425c0e0894fb132296f3e9a8183ab3c7c62212ed;p=fs%2Flustre-release.git fixes possible memory leak on error case path --- diff --git a/lustre/llite/llite_lib.c b/lustre/llite/llite_lib.c index deb06cf..fcf0c64 100644 --- a/lustre/llite/llite_lib.c +++ b/lustre/llite/llite_lib.c @@ -289,6 +289,11 @@ int lustre_common_fill_super(struct super_block *sb, char *lmv, char *lov, ptlrpc_req_finished(request); if (root == NULL || is_bad_inode(root)) { + if (md.lsm != NULL) + obd_free_memmd(sbi->ll_dt_exp, &md.lsm); + if (md.mea != NULL) + obd_free_memmd(sbi->ll_md_exp, + (struct lov_stripe_md**)&md.mea); CERROR("lustre_lite: bad iget4 for root\n"); GOTO(out_root, err = -EBADF); }