]> git.tuebingen.mpg.de Git - paraslash.git/blobdiff - playlist.c
Introduce pass_object_as_shm().
[paraslash.git] / playlist.c
index 826280b9270ff9bc8c9a37f46e376d69a1422671..19a913144586a3b574dccef2b874964dbc7c2610 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * Copyright (C) 2007 Andre Noll <maan@systemlinux.org>
+ * Copyright (C) 2007-2008 Andre Noll <maan@systemlinux.org>
  *
  * Licensed under the GPL v2. For licencing details see COPYING.
  */
@@ -41,12 +41,12 @@ static int add_playlist_entry(char *path, void *data)
        int ret = aft_get_row_of_path(path, &aft_row);
 
        if (ret < 0) {
-               PARA_NOTICE_LOG("%s: %s\n", path, PARA_STRERROR(-ret));
+               PARA_NOTICE_LOG("%s: %s\n", path, para_strerror(-ret));
                return 1;
        }
        ret = score_add(aft_row, -playlist->length);
        if (ret < 0) {
-               PARA_ERROR_LOG("failed to add %s: %s\n", path, PARA_STRERROR(-ret));
+               PARA_ERROR_LOG("failed to add %s: %s\n", path, para_strerror(-ret));
                return ret;
        }
        playlist->length++;
@@ -80,7 +80,7 @@ static int load_playlist(struct osl_row *row, void *data)
 err:
        if (ret != -E_DUMMY_ROW)
                PARA_NOTICE_LOG("unable to load playlist (%s)\n",
-                       PARA_STRERROR(-ret));
+                       para_strerror(-ret));
        return 1;
 }
 
@@ -91,7 +91,7 @@ static int check_playlist_path(char *path, void *data)
        int ret = aft_get_row_of_path(path, &aft_row);
 
        if (ret < 0)
-               para_printf(pb, "%s: %s\n", path, PARA_STRERROR(-ret));
+               para_printf(pb, "%s: %s\n", path, para_strerror(-ret));
        return 1;
 }
 
@@ -104,7 +104,7 @@ static int check_playlist(struct osl_row *row, void *data)
 
        if (ret < 0) {
                para_printf(pb, "failed to get playlist data: %s\n",
-                       PARA_STRERROR(-ret));
+                       para_strerror(-ret));
                return 1;
        }
        if (*playlist_name) { /* skip dummy row */
@@ -133,7 +133,7 @@ int playlist_check_callback(__a_unused const struct osl_object *query,
        osl_rbtree_loop(playlists_table, BLOBCOL_ID, &pb,
                check_playlist);
        result->data = pb.buf;
-       result->size = pb.size;
+       result->size = pb.offset;
        return 1;
 }