aboutsummaryrefslogtreecommitdiffstats
path: root/src/output/ao_plugin.c
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2009-01-18 19:45:51 +0100
committerMax Kellermann <max@duempel.org>2009-01-18 19:45:51 +0100
commit65f2386b39e88fd1ee5af65336e41ba184d31cf2 (patch)
tree695c14ea66774fda67000c3babeea770cf8d96bf /src/output/ao_plugin.c
parenta531a1e65075d27574bc31d4bac7ab20cb750efd (diff)
downloadmpd-65f2386b39e88fd1ee5af65336e41ba184d31cf2.tar.gz
mpd-65f2386b39e88fd1ee5af65336e41ba184d31cf2.tar.xz
mpd-65f2386b39e88fd1ee5af65336e41ba184d31cf2.zip
conf: added config_get_block_unsigned()
Eliminate some more getBlockParam() invocations.
Diffstat (limited to '')
-rw-r--r--src/output/ao_plugin.c11
1 files changed, 1 insertions, 10 deletions
diff --git a/src/output/ao_plugin.c b/src/output/ao_plugin.c
index d20496e2c..f24805de0 100644
--- a/src/output/ao_plugin.c
+++ b/src/output/ao_plugin.c
@@ -80,19 +80,10 @@ audioOutputAo_initDriver(struct audio_output *ao,
struct config_param *param)
{
ao_info *ai;
- char *test;
AoData *ad = newAoData();
- struct block_param *blockParam;
const char *value;
- if ((blockParam = getBlockParam(param, "write_size"))) {
- ad->writeSize = strtol(blockParam->value, &test, 10);
- if (*test != '\0') {
- g_error("\"%s\" is not a valid write size at line %i\n",
- blockParam->value, blockParam->line);
- }
- } else
- ad->writeSize = 1024;
+ ad->writeSize = config_get_block_unsigned(param, "write_size", 1024);
if (driverInitCount == 0) {
ao_initialize();