]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commit
client/Client.cc: fix realloc memory leak
authorDanny Al-Gaaf <danny.al-gaaf@bisect.de>
Wed, 12 Aug 2015 16:38:38 +0000 (18:38 +0200)
committerYan, Zheng <zyan@redhat.com>
Thu, 3 Mar 2016 12:30:07 +0000 (20:30 +0800)
commit16e3e2f0a0dc465ed9079df051215f4758f0ee4d
treed885e6785e8bc0ebcf115c33a33d58149c10bfe4
parentb13ddc0690742b11802e59f34b539987d632ac58
client/Client.cc: fix realloc memory leak

Fix handling of realloc. If realloc() fails it returns NULL, assigning
the return value of realloc() directly to the pointer without checking
for the result will lead to a memory leak.

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
Signed-off-by: Yan, Zheng <zyan@redhat.com>
(cherry picked from commit 4f98dab99c35663de89a06e2dfdbd874f56aed41)
src/client/Client.cc