lib/yajl: use std::span instead of ConstBuffer

This commit is contained in:
Max Kellermann
2022-07-04 18:34:11 +02:00
parent 020c9b41cc
commit baff5e5594
3 changed files with 5 additions and 7 deletions

View File

@@ -30,6 +30,7 @@
#include "event/Call.hxx"
#include "util/Domain.hxx"
#include "util/DeleteDisposer.hxx"
#include "util/SpanCast.hxx"
#include "config/Net.hxx"
#ifdef HAVE_ZEROCONF
@@ -277,8 +278,7 @@ ToJson(const Tag &tag) noexcept
gen.CloseMap();
const auto result = gen.GetBuffer();
return {(const char *)result.data, result.size};
return std::string{ToStringView(gen.GetBuffer())};
}
#endif