tag/IcyMetadataParser: pass std::string_view to icy_parse_tag_item()

This commit is contained in:
Max Kellermann 2023-12-20 19:50:08 +01:00
parent 03352cb4ad
commit 2618294eb7
1 changed files with 5 additions and 2 deletions

View File

@ -7,9 +7,12 @@
#include <algorithm>
#include <cassert>
#include <string_view>
#include <string.h>
using std::string_view_literals::operator""sv;
#ifdef HAVE_ICU_CONVERTER
void
@ -72,9 +75,9 @@ icy_parse_tag_item(TagBuilder &tag,
#ifdef HAVE_ICU_CONVERTER
const IcuConverter *icu_converter,
#endif
const char *name, const char *value) noexcept
std::string_view name, std::string_view value) noexcept
{
if (strcmp(name, "StreamTitle") == 0) {
if (name == "StreamTitle"sv) {
#ifdef HAVE_ICU_CONVERTER
if (icu_converter != nullptr) {
try {