aboutsummaryrefslogtreecommitdiff
path: root/src/song.h
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2008-10-08 10:49:11 +0200
committerMax Kellermann <max@duempel.org>2008-10-08 10:49:11 +0200
commitd562ba5fbbe117585eaade40a8e9c6ef1bf7ca1f (patch)
tree1e82f7b4854c5d15c4ab59c48120da02e4b41be9 /src/song.h
parent25f67da58c671885c86ecfd991f28ec82b6ce1e2 (diff)
song: converted typedef Song to struct song
Again, a data type which can be forward-declared.
Diffstat (limited to 'src/song.h')
-rw-r--r--src/song.h21
1 files changed, 13 insertions, 8 deletions
diff --git a/src/song.h b/src/song.h
index fc50e70c..65892132 100644
--- a/src/song.h
+++ b/src/song.h
@@ -30,21 +30,24 @@
struct client;
-typedef struct _Song {
+struct song {
struct tag *tag;
struct directory *parentDir;
time_t mtime;
char url[sizeof(size_t)];
-} Song;
+};
-Song *
+struct song *
song_alloc(const char *url, struct directory *parent);
-Song *newSong(const char *url, struct directory *parentDir);
+struct song *
+newSong(const char *url, struct directory *parentDir);
-void freeJustSong(Song *);
+void
+freeJustSong(struct song *);
-int updateSongInfo(Song * song);
+int
+updateSongInfo(struct song *song);
/*
* get_song_url - Returns a path of a song in UTF8-encoded form
@@ -52,9 +55,11 @@ int updateSongInfo(Song * song);
* buffer is assumed to be MPD_PATH_MAX or greater (including
* terminating '\0').
*/
-char *get_song_url(char *path_max_tmp, Song * song);
+char *
+get_song_url(char *path_max_tmp, struct song *song);
-static inline int song_is_file(const Song *song)
+static inline int
+song_is_file(const struct song *song)
{
return !!song->parentDir;
}