diff options
author | Max Kellermann <max@duempel.org> | 2008-09-07 13:53:55 +0200 |
---|---|---|
committer | Max Kellermann <max@duempel.org> | 2008-09-07 13:53:55 +0200 |
commit | dc8b64fdef1f8bc4499eef3aca17ed336ea3569b (patch) | |
tree | ba98b059e544ddecd774bd4c97ce66898cba3be0 /src/tag_print.c | |
parent | 5609a1fcd09c498fdcdfe0f535052e8d8c3ef05c (diff) |
pass "struct client" to dbUtils.c, song.c, tag_print.c
Don't pass the raw file descriptor around. This migration patch is
rather large, because all of the sources have inter dependencies - we
have to change all of them at the same time.
Diffstat (limited to 'src/tag_print.c')
-rw-r--r-- | src/tag_print.c | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/src/tag_print.c b/src/tag_print.c index c5d50880..0ed10789 100644 --- a/src/tag_print.c +++ b/src/tag_print.c @@ -19,28 +19,30 @@ #include "tag_print.h" #include "tag.h" #include "tag_internal.h" -#include "myfprintf.h" +#include "client.h" #include "song.h" -void tag_print_types(int fd) +void tag_print_types(struct client *client) { int i; for (i = 0; i < TAG_NUM_OF_ITEM_TYPES; i++) { if (ignoreTagItems[i] == 0) - fdprintf(fd, "tagtype: %s\n", mpdTagItemKeys[i]); + client_printf(client, "tagtype: %s\n", + mpdTagItemKeys[i]); } } -void tag_print(int fd, const struct tag *tag) +void tag_print(struct client *client, const struct tag *tag) { int i; if (tag->time >= 0) - fdprintf(fd, SONG_TIME "%i\n", tag->time); + client_printf(client, SONG_TIME "%i\n", tag->time); for (i = 0; i < tag->numOfItems; i++) { - fdprintf(fd, "%s: %s\n", mpdTagItemKeys[tag->items[i]->type], - tag->items[i]->value); + client_printf(client, "%s: %s\n", + mpdTagItemKeys[tag->items[i]->type], + tag->items[i]->value); } } |