diff options
author | Danny Al-Gaaf <danny.al-gaaf@bisect.de> | 2014-06-23 11:20:09 +0200 |
---|---|---|
committer | Danny Al-Gaaf <danny.al-gaaf@bisect.de> | 2014-06-23 11:20:09 +0200 |
commit | 8700aa0e6380b533a06d5c098f2fe83db9577ff5 (patch) | |
tree | bcc4ba34827e0c56b8e67078b8a11bd86f3a6380 /src/test/libradosstriper | |
parent | MDCache.cc: init 'umaster::ls' with NULL in contructor (diff) | |
download | ceph-8700aa0e6380b533a06d5c098f2fe83db9577ff5.tar.xz ceph-8700aa0e6380b533a06d5c098f2fe83db9577ff5.zip |
test/libradosstriper/striping.cc: fix potential memory leak
Fix for:
[src/test/libradosstriper/striping.cc:138]: (error) Allocation with
getObjName, stat doesn't release it
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
Diffstat (limited to 'src/test/libradosstriper')
-rw-r--r-- | src/test/libradosstriper/striping.cc | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/test/libradosstriper/striping.cc b/src/test/libradosstriper/striping.cc index c65f0498de5..3533a61fc70 100644 --- a/src/test/libradosstriper/striping.cc +++ b/src/test/libradosstriper/striping.cc @@ -135,7 +135,8 @@ protected: // check we do not have an extra object behind uint64_t rados_size; time_t mtime; - ASSERT_EQ(-ENOENT, ioctx.stat(getObjName(soid, nb_objects), &rados_size, &mtime)); + std::string oid = getObjName(soid, nb_objects); + ASSERT_EQ(-ENOENT, ioctx.stat(oid, &rados_size, &mtime)); } }; |