aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2008-09-08 11:43:38 +0200
committerMax Kellermann <max@duempel.org>2008-09-08 11:43:38 +0200
commit3f6fe915ebff003b907bc0c70502d21691b50095 (patch)
tree1d144aa6605ce6a4efb59fc2d724d0c8fe919a2c
parentbe046b25a4e2583f63d6b3da680e6451957750e4 (diff)
downloadmpd-3f6fe915ebff003b907bc0c70502d21691b50095.tar.gz
mpd-3f6fe915ebff003b907bc0c70502d21691b50095.tar.xz
mpd-3f6fe915ebff003b907bc0c70502d21691b50095.zip
output: const plugin structures
Since the plugin struct is never modified, we should store it in constant locations.
-rw-r--r--src/audioOutputs/audioOutput_alsa.c2
-rw-r--r--src/audioOutputs/audioOutput_ao.c2
-rw-r--r--src/audioOutputs/audioOutput_fifo.c2
-rw-r--r--src/audioOutputs/audioOutput_jack.c2
-rw-r--r--src/audioOutputs/audioOutput_mvp.c2
-rw-r--r--src/audioOutputs/audioOutput_null.c2
-rw-r--r--src/audioOutputs/audioOutput_oss.c2
-rw-r--r--src/audioOutputs/audioOutput_osx.c2
-rw-r--r--src/audioOutputs/audioOutput_pulse.c2
-rw-r--r--src/audioOutputs/audioOutput_shout.c2
-rw-r--r--src/output_api.h2
11 files changed, 11 insertions, 11 deletions
diff --git a/src/audioOutputs/audioOutput_alsa.c b/src/audioOutputs/audioOutput_alsa.c
index 9917c4629..948e0ad2a 100644
--- a/src/audioOutputs/audioOutput_alsa.c
+++ b/src/audioOutputs/audioOutput_alsa.c
@@ -413,7 +413,7 @@ static int alsa_playAudio(struct audio_output *audioOutput,
return 0;
}
-struct audio_output_plugin alsaPlugin = {
+const struct audio_output_plugin alsaPlugin = {
"alsa",
alsa_testDefault,
alsa_initDriver,
diff --git a/src/audioOutputs/audioOutput_ao.c b/src/audioOutputs/audioOutput_ao.c
index b02884751..1aa57cba2 100644
--- a/src/audioOutputs/audioOutput_ao.c
+++ b/src/audioOutputs/audioOutput_ao.c
@@ -242,7 +242,7 @@ static int audioOutputAo_play(struct audio_output *audioOutput,
return 0;
}
-struct audio_output_plugin aoPlugin = {
+const struct audio_output_plugin aoPlugin = {
"ao",
NULL,
audioOutputAo_initDriver,
diff --git a/src/audioOutputs/audioOutput_fifo.c b/src/audioOutputs/audioOutput_fifo.c
index 60c951387..be40b25e3 100644
--- a/src/audioOutputs/audioOutput_fifo.c
+++ b/src/audioOutputs/audioOutput_fifo.c
@@ -272,7 +272,7 @@ static int fifo_playAudio(struct audio_output *audioOutput,
return 0;
}
-struct audio_output_plugin fifoPlugin = {
+const struct audio_output_plugin fifoPlugin = {
"fifo",
NULL, /* testDefaultDeviceFunc */
fifo_initDriver,
diff --git a/src/audioOutputs/audioOutput_jack.c b/src/audioOutputs/audioOutput_jack.c
index 884a3d197..04da026f9 100644
--- a/src/audioOutputs/audioOutput_jack.c
+++ b/src/audioOutputs/audioOutput_jack.c
@@ -430,7 +430,7 @@ static int jack_playAudio(struct audio_output *audioOutput,
return 0;
}
-struct audio_output_plugin jackPlugin = {
+const struct audio_output_plugin jackPlugin = {
"jack",
jack_testDefault,
jack_initDriver,
diff --git a/src/audioOutputs/audioOutput_mvp.c b/src/audioOutputs/audioOutput_mvp.c
index c232b73b1..ba41c1703 100644
--- a/src/audioOutputs/audioOutput_mvp.c
+++ b/src/audioOutputs/audioOutput_mvp.c
@@ -257,7 +257,7 @@ static int mvp_playAudio(struct audio_output *audioOutput,
return 0;
}
-struct audio_output_plugin mvpPlugin = {
+const struct audio_output_plugin mvpPlugin = {
"mvp",
mvp_testDefault,
mvp_initDriver,
diff --git a/src/audioOutputs/audioOutput_null.c b/src/audioOutputs/audioOutput_null.c
index eea1cfcbe..28e58d49e 100644
--- a/src/audioOutputs/audioOutput_null.c
+++ b/src/audioOutputs/audioOutput_null.c
@@ -63,7 +63,7 @@ static void null_dropBufferedAudio(struct audio_output *audioOutput)
timer_reset(audioOutput->data);
}
-struct audio_output_plugin nullPlugin = {
+const struct audio_output_plugin nullPlugin = {
"null",
NULL,
null_initDriver,
diff --git a/src/audioOutputs/audioOutput_oss.c b/src/audioOutputs/audioOutput_oss.c
index a6c385c71..f65312fc9 100644
--- a/src/audioOutputs/audioOutput_oss.c
+++ b/src/audioOutputs/audioOutput_oss.c
@@ -549,7 +549,7 @@ static int oss_playAudio(struct audio_output *audioOutput,
return 0;
}
-struct audio_output_plugin ossPlugin = {
+const struct audio_output_plugin ossPlugin = {
"oss",
oss_testDefault,
oss_initDriver,
diff --git a/src/audioOutputs/audioOutput_osx.c b/src/audioOutputs/audioOutput_osx.c
index 1cdcb473c..e8a65c453 100644
--- a/src/audioOutputs/audioOutput_osx.c
+++ b/src/audioOutputs/audioOutput_osx.c
@@ -355,7 +355,7 @@ static int osx_play(struct audio_output *audioOutput,
return 0;
}
-struct audio_output_plugin osxPlugin = {
+const struct audio_output_plugin osxPlugin = {
"osx",
osx_testDefault,
osx_initDriver,
diff --git a/src/audioOutputs/audioOutput_pulse.c b/src/audioOutputs/audioOutput_pulse.c
index 6d9b385ca..8e76b7781 100644
--- a/src/audioOutputs/audioOutput_pulse.c
+++ b/src/audioOutputs/audioOutput_pulse.c
@@ -200,7 +200,7 @@ static int pulse_playAudio(struct audio_output *audioOutput,
return 0;
}
-struct audio_output_plugin pulsePlugin = {
+const struct audio_output_plugin pulsePlugin = {
"pulse",
pulse_testDefault,
pulse_initDriver,
diff --git a/src/audioOutputs/audioOutput_shout.c b/src/audioOutputs/audioOutput_shout.c
index ee21fabe6..6c5e3c56b 100644
--- a/src/audioOutputs/audioOutput_shout.c
+++ b/src/audioOutputs/audioOutput_shout.c
@@ -680,7 +680,7 @@ static void myShout_setTag(struct audio_output *audioOutput,
sd->tagToSend = 1;
}
-struct audio_output_plugin shoutPlugin = {
+const struct audio_output_plugin shoutPlugin = {
"shout",
NULL,
myShout_initDriver,
diff --git a/src/output_api.h b/src/output_api.h
index 9d17d8664..ca4c8c5a1 100644
--- a/src/output_api.h
+++ b/src/output_api.h
@@ -28,7 +28,7 @@
#include "log.h"
#include "os_compat.h"
-#define DISABLED_AUDIO_OUTPUT_PLUGIN(plugin) struct audio_output_plugin plugin;
+#define DISABLED_AUDIO_OUTPUT_PLUGIN(plugin) const struct audio_output_plugin plugin;
struct audio_output;