diff options
author | Mohit Agrawal <moagrawa@redhat.com> | 2017-01-13 12:17:05 +0530 |
---|---|---|
committer | Niels de Vos <ndevos@redhat.com> | 2017-01-16 01:32:13 -0800 |
commit | afdd83a9b69573b854e732795c0bcba0a00d6c0f (patch) | |
tree | d3fff9461fa8e62dc72a037ef737f008c9e6b413 /tests | |
parent | 2041fb7872fa6672e9164fd2a12aaf80e6ef3ebd (diff) |
upcall: Resolve dict leak from up_(f)removexattr in upcall code path
Problem: In up_(f)removexattr() dict_for_key_value() is used to create a
new dict. This dict is not correctly unref'd and gets leaked.
Solution: To avoid the leak up_(f)removexattr() now also does a
dict_unref() on the newly created dict.
While reviewing the code in up_(f)setxattr() for a similar problem, it
was noticed that there is an extra dict created. There is no need for
this copy, upcall_local_init() can just take the dict that was passed as
argument to the FOP.
BUG: 1412917
Change-Id: I5bb9a7d99f5087af11c19ae722de62bdb5ad1498
Signed-off-by: Mohit Agrawal <moagrawa@redhat.com>
Reviewed-on: http://review.gluster.org/16392
NetBSD-regression: NetBSD Build System <jenkins@build.gluster.org>
CentOS-regression: Gluster Build System <jenkins@build.gluster.org>
Reviewed-by: Niels de Vos <ndevos@redhat.com>
Smoke: Gluster Build System <jenkins@build.gluster.org>
Diffstat (limited to 'tests')
0 files changed, 0 insertions, 0 deletions