X-Git-Url: http://git.tuebingen.mpg.de/?a=blobdiff_plain;f=audiod.c;h=a5a774376b37c50eba92a76a02b1389bd6df67f4;hb=refs%2Fheads%2Fpu;hp=bb5dd7037c61bc77d737422b45c77607527950a3;hpb=d955fb7bc5640767c14560e06e6f9c47d3cb49c5;p=paraslash.git diff --git a/audiod.c b/audiod.c index bb5dd703..a03a4bda 100644 --- a/audiod.c +++ b/audiod.c @@ -46,8 +46,9 @@ static struct lls_parse_result *lpr; #define OPT_UINT32_VAL(_name) (lls_uint32_val(0, OPT_RESULT(_name))) __printf_2_3 void (*para_log)(int, const char*, ...) = daemon_log; -/** define the array containing all supported audio formats */ -const char *audio_formats[] = {AUDIOD_AUDIO_FORMAT_ARRAY NULL}; +/* Audio formats supported by audiod */ +static const char *audio_formats[] = {AUDIOD_AUDIO_FORMAT_ARRAY}; +#define NUM_AUDIO_FORMATS ARRAY_SIZE(audio_formats) /** Defines how audiod handles one supported audio format. */ struct audio_format_info { @@ -1520,5 +1521,6 @@ out: PARA_ERROR_LOG("%s\n", errctx); if (ret < 0) PARA_EMERG_LOG("%s\n", para_strerror(-ret)); + free(get_confdir()); return ret < 0? EXIT_FAILURE : EXIT_SUCCESS; }