core: convert save-xml.c to C++

This includes using the C++ version of membuffer. There appears
to not have been a leak, because the buffer is freed in
flush_buffer(), but usage was somewhat inconsistent and hard to
follow.

Also, convert some string handling to std::string to avoid free()
madness.

Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
This commit is contained in:
Berthold Stoeger 2024-02-28 06:36:48 +01:00 committed by Michael Keller
parent 76c2069fa8
commit a032d9c979
3 changed files with 30 additions and 46 deletions

View file

@ -159,7 +159,7 @@ set(SUBSURFACE_CORE_LIB_SRCS
save-html.c
save-html.h
save-profiledata.c
save-xml.c
save-xml.cpp
selection.cpp
selection.h
sha1.c