Skip to content

Commit

Permalink
libceph: fix parse options memory leak
Browse files Browse the repository at this point in the history
ceph_destroy_options does not free opt->mon_addr that
is allocated in ceph_parse_options.

Signed-off-by: Noah Watkins <noahwatkins@gmail.com>
Signed-off-by: Sage Weil <sage@newdream.net>
  • Loading branch information
Noah Watkins authored and Sage Weil committed Sep 16, 2011
1 parent c0d5f9d commit 1cad789
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions net/ceph/ceph_common.c
Original file line number Diff line number Diff line change
Expand Up @@ -232,6 +232,7 @@ void ceph_destroy_options(struct ceph_options *opt)
ceph_crypto_key_destroy(opt->key);
kfree(opt->key);
}
kfree(opt->mon_addr);
kfree(opt);
}
EXPORT_SYMBOL(ceph_destroy_options);
Expand Down

0 comments on commit 1cad789

Please sign in to comment.