diff options
author | Artur Wojcik <artur.wojcik@intel.com> | 2009-12-10 20:03:40 +0100 |
---|---|---|
committer | Dan Williams <dan.j.williams@intel.com> | 2009-12-10 20:03:40 +0100 |
commit | 389508223e22807e7fb42ada4ad9d61416cc7afd (patch) | |
tree | 705cc80bec45db55ba10f6f40ba8523e9c48bda2 /super-intel.c | |
parent | Fix for memory leak defect. (diff) | |
download | mdadm-389508223e22807e7fb42ada4ad9d61416cc7afd.tar.xz mdadm-389508223e22807e7fb42ada4ad9d61416cc7afd.zip |
Fix for memory leak defect.
Possible memory leak. Dynamic memory stored in 'dev' and 'dev' allocated
through function 'malloc' can be lost on exit path.
Signed-off-by: Artur Wojcik <artur.wojcik@intel.com>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Diffstat (limited to 'super-intel.c')
-rw-r--r-- | super-intel.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/super-intel.c b/super-intel.c index 5c967b2a..d87b2b03 100644 --- a/super-intel.c +++ b/super-intel.c @@ -2810,6 +2810,8 @@ static int init_super_imsm_volume(struct supertype *st, mdu_array_info_t *info, map->ddf = 1; if (info->level == 1 && info->raid_disks > 2) { + free(dev); + free(dv); fprintf(stderr, Name": imsm does not support more than 2 disks" "in a raid1 volume\n"); return 0; |