From 07fcf091a2e33b9de0b3faf855df482e03a82223 Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Wed, 14 Aug 2019 19:42:10 +0200 Subject: [PATCH] tag/MixRamp: pass StringView to ParseMixRampVorbis() --- src/tag/MixRamp.cxx | 4 ++-- src/tag/MixRamp.hxx | 3 ++- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/tag/MixRamp.cxx b/src/tag/MixRamp.cxx index 443ccaf57..6e215d2e9 100644 --- a/src/tag/MixRamp.cxx +++ b/src/tag/MixRamp.cxx @@ -67,10 +67,10 @@ ParseMixRampTag(MixRampInfo &info, } bool -ParseMixRampVorbis(MixRampInfo &info, const char *entry) noexcept +ParseMixRampVorbis(MixRampInfo &info, StringView entry) noexcept { struct VorbisCommentEntry { - const char *entry; + StringView entry; gcc_pure StringView operator[](StringView n) const noexcept { diff --git a/src/tag/MixRamp.hxx b/src/tag/MixRamp.hxx index 3a58cd456..5264b7f4b 100644 --- a/src/tag/MixRamp.hxx +++ b/src/tag/MixRamp.hxx @@ -20,6 +20,7 @@ #ifndef MPD_TAG_MIXRAMP_HXX #define MPD_TAG_MIXRAMP_HXX +struct StringView; class MixRampInfo; bool @@ -27,6 +28,6 @@ ParseMixRampTag(MixRampInfo &info, const char *name, const char *value) noexcept; bool -ParseMixRampVorbis(MixRampInfo &info, const char *entry) noexcept; +ParseMixRampVorbis(MixRampInfo &info, StringView entry) noexcept; #endif