X-Git-Url: http://git.tuebingen.mpg.de/?p=paraslash.git;a=blobdiff_plain;f=flac_afh.c;h=6e23683937f6932aaa739095ef8281fc9075da55;hp=385d4f0c3a0235b9be24cdc83666308c30b959b8;hb=3685a9093ae12ff9ce02fc58e607eb9b63894443;hpb=121015ff5cdbe6af7b84f6245ebe62fe2a52a859 diff --git a/flac_afh.c b/flac_afh.c index 385d4f0c..6e236839 100644 --- a/flac_afh.c +++ b/flac_afh.c @@ -1,8 +1,4 @@ -/* - * Copyright (C) 2011 Andre Noll - * - * Licensed under the GPL v2. For licencing details see COPYING. - */ +/* Copyright (C) 2011 Andre Noll , see file COPYING. */ /** \file flac_afh.c Audio format handler for flac files. */ @@ -391,6 +387,7 @@ static int flac_afh_read_chunks(struct private_flac_afh_data *pfad) break; } afhi->chunks_total = c; + set_max_chunk_size(afhi); ret = 1; free_decoder: FLAC__stream_decoder_finish(decoder); @@ -518,13 +515,12 @@ free_pfad: static const char * const flac_suffixes[] = {"flac", NULL}; /** - * The init function of the flac audio format handler. + * The audio format handler for flac (free lossless audio decoder). * - * \param afh pointer to the struct to initialize + * It depends on libflac and on libogg. */ -void flac_afh_init(struct audio_format_handler *afh) -{ - afh->get_file_info = flac_get_file_info, - afh->suffixes = flac_suffixes; - afh->rewrite_tags = flac_rewrite_tags; -} +const struct audio_format_handler flac_afh = { + .get_file_info = flac_get_file_info, + .suffixes = flac_suffixes, + .rewrite_tags = flac_rewrite_tags, +};