]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commit
<comomon> fix buffer out-of-bounds in HTMLFormatter
authorliubingrun <liubr1@chinatelecom.cn>
Thu, 24 Oct 2024 10:19:28 +0000 (06:19 -0400)
committerCasey Bodley <cbodley@redhat.com>
Mon, 16 Dec 2024 18:21:04 +0000 (13:21 -0500)
commit70e6e82dbb806d0aee71faeb3f15402970c9e493
tree436b5756bf69b5f30ffab4a08383362b82133408
parent2cd364d11bcd0454c394459389b9e5a07a074827
<comomon> fix buffer out-of-bounds in HTMLFormatter

Use boost small_vector to allocate more buffer when content is too
long to fit in the buffer pre-alloced

A unittest is also added.

Signed-off-by: liubingrun <liubr1@chinatelecom.cn>
(cherry picked from commit 38601d0c9ea0b6fe32a27cebeb34ec785c7df676)
src/common/HTMLFormatter.cc
src/test/common/CMakeLists.txt
src/test/common/test_htmlformatter.cc [new file with mode: 0644]