aboutsummaryrefslogtreecommitdiffstats
path: root/src/decoder/flac_plugin.c
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2008-11-01 14:55:23 +0100
committerMax Kellermann <max@duempel.org>2008-11-01 14:55:23 +0100
commit4c1b96c30721f78d9251a8074d4d516c37e755b9 (patch)
treec1473bea5ff2fb12560c22a2764189adba96b83b /src/decoder/flac_plugin.c
parent0b614fbaae9089d6d1ce981735a51f2a5b3cbf65 (diff)
downloadmpd-4c1b96c30721f78d9251a8074d4d516c37e755b9.tar.gz
mpd-4c1b96c30721f78d9251a8074d4d516c37e755b9.tar.xz
mpd-4c1b96c30721f78d9251a8074d4d516c37e755b9.zip
decoder: make the suffixes and mime_types arrays really const
The strings were constant, but the pointers weren't. C syntax is somewhat tricky..
Diffstat (limited to '')
-rw-r--r--src/decoder/flac_plugin.c20
1 files changed, 11 insertions, 9 deletions
diff --git a/src/decoder/flac_plugin.c b/src/decoder/flac_plugin.c
index 8b49ec3e5..05517db27 100644
--- a/src/decoder/flac_plugin.c
+++ b/src/decoder/flac_plugin.c
@@ -429,11 +429,13 @@ oggflac_try_decode(struct input_stream *inStream)
ogg_stream_type_detect(inStream) == FLAC;
}
-static const char *oggflac_suffixes[] = { "ogg", "oga", NULL };
-static const char *oggflac_mime_types[] = { "audio/x-flac+ogg",
- "application/ogg",
- "application/x-ogg",
- NULL };
+static const char *const oggflac_suffixes[] = { "ogg", "oga", NULL };
+static const char *const oggflac_mime_types[] = {
+ "audio/x-flac+ogg",
+ "application/ogg",
+ "application/x-ogg",
+ NULL
+};
const struct decoder_plugin oggflacPlugin = {
.name = "oggflac",
@@ -447,10 +449,10 @@ const struct decoder_plugin oggflacPlugin = {
#endif /* FLAC_API_VERSION_CURRENT >= 7 */
-static const char *flacSuffixes[] = { "flac", NULL };
-static const char *flac_mime_types[] = { "audio/x-flac",
- "application/x-flac",
- NULL };
+static const char *const flacSuffixes[] = { "flac", NULL };
+static const char *const flac_mime_types[] = {
+ "audio/x-flac", "application/x-flac", NULL
+};
const struct decoder_plugin flacPlugin = {
.name = "flac",