diff options
author | Max Kellermann <max@duempel.org> | 2008-11-04 16:55:11 +0100 |
---|---|---|
committer | Max Kellermann <max@duempel.org> | 2008-11-04 16:55:11 +0100 |
commit | e26bff9b92b78999aadf80afa6c674c30d6d7be1 (patch) | |
tree | fb4148df416fcdcafff937f062b35b90fd2071ff /src | |
parent | d7b2d93ccc6ee435b41d28f8e31eeeacb3cad58f (diff) | |
download | mpd-e26bff9b92b78999aadf80afa6c674c30d6d7be1.tar.gz mpd-e26bff9b92b78999aadf80afa6c674c30d6d7be1.tar.xz mpd-e26bff9b92b78999aadf80afa6c674c30d6d7be1.zip |
tag: added tag_is_empty()
Diffstat (limited to '')
-rw-r--r-- | src/tag.h | 10 |
1 files changed, 10 insertions, 0 deletions
@@ -90,6 +90,16 @@ static inline void tag_add_item(struct tag *tag, enum tag_type itemType, struct tag *tag_dup(const struct tag *tag); /** + * Returns true if the tag contains no items. This ignores the "time" + * attribute. + */ +static inline bool +tag_is_empty(const struct tag *tag) +{ + return tag->numOfItems == 0; +} + +/** * Checks whether the tag contains one or more items with * the specified type. */ |