diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/audioOutputs/audioOutput_shout.c | 19 | ||||
-rw-r--r-- | src/listen.c | 5 |
2 files changed, 22 insertions, 2 deletions
diff --git a/src/audioOutputs/audioOutput_shout.c b/src/audioOutputs/audioOutput_shout.c index 2c0cdd898..8eb4f4672 100644 --- a/src/audioOutputs/audioOutput_shout.c +++ b/src/audioOutputs/audioOutput_shout.c @@ -224,6 +224,25 @@ static int myShout_initDriver(AudioOutput * audioOutput, ConfigParam * param) { exit(EXIT_FAILURE); } + /* optional paramters */ + blockParam = getBlockParam(param, "genre"); + if(blockParam && shout_set_genre(sd->shoutConn, blockParam->value)) { + ERROR("error configuring shout defined at line %i: %s\n", + param->line, + shout_get_error(sd->shoutConn)); + exit(EXIT_FAILURE); + } + + blockParam = getBlockParam(param, "description"); + if(blockParam && shout_set_description(sd->shoutConn, + blockParam->value)) + { + ERROR("error configuring shout defined at line %i: %s\n", + param->line, + shout_get_error(sd->shoutConn)); + exit(EXIT_FAILURE); + } + { char temp[11]; memset(temp, 0, sizeof(temp)); diff --git a/src/listen.c b/src/listen.c index 7446f2e91..9d33698a0 100644 --- a/src/listen.c +++ b/src/listen.c @@ -151,8 +151,9 @@ static int establishListen(unsigned int port, ConfigParam * param) { } if(bind(sock,addrp,addrlen)<0) { - ERROR("unable to bind port %i (for address at line %i): %s\n", - port, param->line, strerror(errno)); + ERROR("unable to bind port %u", port); + if(param) ERROR(" (for address at line %i)", param->line); + ERROR(": %s\n", strerror(errno)); ERROR("maybe MPD is still running?\n"); exit(EXIT_FAILURE); } |