aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorEric Wong <normalperson@yhbt.net>2008-09-07 19:14:47 +0200
committerMax Kellermann <max@duempel.org>2008-09-07 19:14:47 +0200
commita5f68b3cfc51ecb21817fcbf23c79f9a0953ba71 (patch)
tree194baea5e44c3b0e749d23e4b9b62d2c2749fe09 /src
parent3c4de5b560691bb877d47f475932b3c8f5751b93 (diff)
downloadmpd-a5f68b3cfc51ecb21817fcbf23c79f9a0953ba71.tar.gz
mpd-a5f68b3cfc51ecb21817fcbf23c79f9a0953ba71.tar.xz
mpd-a5f68b3cfc51ecb21817fcbf23c79f9a0953ba71.zip
tag: oops, of course items is now ** and not *
Gah, it seems like doing sizeof here either way is error prone. Too easy to leave out a '*' character we can forget.
Diffstat (limited to 'src')
-rw-r--r--src/tag.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/tag.c b/src/tag.c
index 35835f1a1..c75e62ec2 100644
--- a/src/tag.c
+++ b/src/tag.c
@@ -57,7 +57,7 @@ mpd_sint8 ignoreTagItems[TAG_NUM_OF_ITEM_TYPES];
static size_t items_size(const struct tag *tag)
{
- return (tag->numOfItems * sizeof(struct tag_item));
+ return (tag->numOfItems * sizeof(struct tag_item *));
}
void tag_lib_init(void)
@@ -427,7 +427,7 @@ static void appendToTagItems(struct tag *tag, enum tag_type type,
tag->items = xmalloc(items_size(tag));
memcpy(tag->items, bulk.items,
- items_size(tag) - sizeof(struct tag_item));
+ items_size(tag) - sizeof(struct tag_item *));
}
pthread_mutex_lock(&tag_pool_lock);