aboutsummaryrefslogtreecommitdiffstats
path: root/src/decoder/MadDecoderPlugin.cxx
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2013-11-28 18:48:35 +0100
committerMax Kellermann <max@duempel.org>2013-11-28 18:48:35 +0100
commitaf4133e3c92c78cc19ff14b876be6afcab1db091 (patch)
treeda38387995bde630b20f81a717862ae21d19bb48 /src/decoder/MadDecoderPlugin.cxx
parenta788b7e747bc21b9aadee45dd028fa6198af794e (diff)
downloadmpd-af4133e3c92c78cc19ff14b876be6afcab1db091.tar.gz
mpd-af4133e3c92c78cc19ff14b876be6afcab1db091.tar.xz
mpd-af4133e3c92c78cc19ff14b876be6afcab1db091.zip
Util/StringUtil: add StringStartsWith()
Replaces GLib's g_str_has_prefix().
Diffstat (limited to '')
-rw-r--r--src/decoder/MadDecoderPlugin.cxx3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/decoder/MadDecoderPlugin.cxx b/src/decoder/MadDecoderPlugin.cxx
index 4dfb752f0..0359840fc 100644
--- a/src/decoder/MadDecoderPlugin.cxx
+++ b/src/decoder/MadDecoderPlugin.cxx
@@ -26,6 +26,7 @@
#include "tag/TagRva2.hxx"
#include "tag/TagHandler.hxx"
#include "CheckAudioFormat.hxx"
+#include "util/StringUtil.hxx"
#include "util/ASCII.hxx"
#include "util/Error.hxx"
#include "util/Domain.hxx"
@@ -689,7 +690,7 @@ parse_lame(struct lame *lame, struct mad_bitptr *ptr, int *bitlen)
/* This is technically incorrect, since the encoder might not be lame.
* But there's no other way to determine if this is a lame tag, and we
* wouldn't want to go reading a tag that's not there. */
- if (!g_str_has_prefix(lame->encoder, "LAME"))
+ if (!StringStartsWith(lame->encoder, "LAME"))
return false;
if (sscanf(lame->encoder+4, "%u.%u",