X-Git-Url: http://git.tuebingen.mpg.de/?p=paraslash.git;a=blobdiff_plain;f=afh.c;h=5b1cfe9bd1bd367939b9df2ddce2e4069c6df70d;hp=b76c72fdab6dbe445b1466de76c4f3dd58e33b92;hb=4744d937c4160898d1fe151257606430750e580c;hpb=5ac6b5f44f64ff9a2f0e01a65013da829edfab9e diff --git a/afh.c b/afh.c index b76c72fd..5b1cfe9b 100644 --- a/afh.c +++ b/afh.c @@ -18,9 +18,6 @@ #include "version.h" static struct afh_args_info conf; -/** The list of all status items */ -const char *status_item_list[] = {STATUS_ITEM_ARRAY}; - INIT_AFH_ERRLISTS; static int loglevel; @@ -187,8 +184,10 @@ int main(int argc, char **argv) int ret2; ret = mmap_full_file(conf.inputs[i], O_RDONLY, &audio_file_data, &audio_file_size, &fd); - if (ret < 0) + if (ret < 0) { + PARA_ERROR_LOG("failed to mmap \"%s\"\n", conf.inputs[i]); goto out; + } ret = compute_afhi(conf.inputs[i], audio_file_data, audio_file_size, fd, &afhi); if (ret < 0) @@ -205,13 +204,7 @@ int main(int argc, char **argv) print_chunk_table(&afhi); printf("\n"); } - free(afhi.techinfo); - free(afhi.tags.artist); - free(afhi.tags.title); - free(afhi.tags.year); - free(afhi.tags.album); - free(afhi.tags.comment); - free(afhi.chunk_table); + clear_afhi(&afhi); ret2 = para_munmap(audio_file_data, audio_file_size); if (ret2 < 0 && ret >= 0) ret = ret2;