]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commit
common/BackTrace: let abi::__cxa_demangle() do the malloc 37045/head
authorKefu Chai <kchai@redhat.com>
Wed, 9 Sep 2020 00:42:24 +0000 (08:42 +0800)
committerKefu Chai <kchai@redhat.com>
Thu, 17 Sep 2020 07:24:37 +0000 (15:24 +0800)
commit141f23480e4851d4783877e14577c5792862dd6b
tree9b8a853704754c20037ec087fe9a92bb6bf6e78b
parentea6abcf34c11c80dec507f7dee8babd26440196c
common/BackTrace: let abi::__cxa_demangle() do the malloc

also use the returned length for constructing the string_view to be
appended.

we could reuse the buffer across multiple demangle() call for saving the
calls to malloc()/free(). but the upside of this change is that it's
simpler.

Signed-off-by: Kefu Chai <kchai@redhat.com>
src/common/BackTrace.cc