diff options
author | Alasdair Kergon <agk@redhat.com> | 2007-09-17 16:02:46 +0000 |
---|---|---|
committer | Alasdair Kergon <agk@redhat.com> | 2007-09-17 16:02:46 +0000 |
commit | 9eea0107ba57aba78fb126794cfbf5110273864c (patch) | |
tree | b153a4fc4ca491616d889779237859a9ee5acc31 /lib/datastruct | |
parent | 7d6a7e7d3b4ed69b85977783cddcf56900fd4d6b (diff) | |
download | lvm2-9eea0107ba57aba78fb126794cfbf5110273864c.tar.gz |
Fix strdup memory leak in str_list_dup().
Diffstat (limited to 'lib/datastruct')
-rw-r--r-- | lib/datastruct/str_list.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/datastruct/str_list.c b/lib/datastruct/str_list.c index 3c259cd25..1d8c2e637 100644 --- a/lib/datastruct/str_list.c +++ b/lib/datastruct/str_list.c @@ -74,7 +74,7 @@ int str_list_dup(struct dm_pool *mem, struct list *sllnew, list_init(sllnew); list_iterate_items(sl, sllold) { - if (!str_list_add(mem, sllnew, strdup(sl->str))) { + if (!str_list_add(mem, sllnew, dm_pool_strdup(mem, sl->str))) { stack; return 0; } |