aft.c: Add GPL header.
[paraslash.git] / aft.c
diff --git a/aft.c b/aft.c
index 1a0fdc79d5f591172b9edadb759baba072563b3a..d1c46ba0255da44bf5d42a4fa83aa1c4db53a7c8 100644 (file)
--- a/aft.c
+++ b/aft.c
@@ -1,3 +1,11 @@
+/*
+ * Copyright (C) 2007 Andre Noll <maan@systemlinux.org>
+ *
+ * Licensed under the GPL v2. For licencing details see COPYING.
+ */
+
+/** \file aft.c Audio file table functions. */
+
 #include "para.h"
 #include "error.h"
 #include <sys/mman.h>
@@ -1722,10 +1730,12 @@ static int check_audio_file(struct osl_row *row, void *data)
        }
        ret = lyr_get_name_by_id(afsi.lyrics_id, &blob_name);
        if (ret < 0)
-               para_printf(pb, "%s lyrics id: %s\n", path, PARA_STRERROR(-ret));
+               para_printf(pb, "%s lyrics id %u: %s\n", path, afsi.lyrics_id,
+                       PARA_STRERROR(-ret));
        ret = img_get_name_by_id(afsi.image_id, &blob_name);
        if (ret < 0)
-               para_printf(pb, "%s image id: %s\n", path, PARA_STRERROR(-ret));
+               para_printf(pb, "%s image id %u: %s\n", path, afsi.image_id,
+                       PARA_STRERROR(-ret));
        return 1;
 }
 
@@ -1733,9 +1743,8 @@ int aft_check_callback(__a_unused const struct osl_object *query, struct osl_obj
 {
        struct para_buffer pb = {.buf = NULL};
 
+       para_printf(&pb, "checking audio file table...\n");
        audio_file_loop(&pb, check_audio_file);
-       if (!pb.size)
-               return 0;
        result->data = pb.buf;
        result->size = pb.size;
        return 1;