From 02e8c000d1eaa2ff3c81bf59b8293b8912d5be3c Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Wed, 8 Oct 2008 11:06:26 +0200 Subject: song: song_file_update() returns bool Instead of returning 0 or -1, return true on success and false on failure. This seems more natural, and when the C library was designed, there was no "bool" data type. --- src/song.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/song.c') diff --git a/src/song.c b/src/song.c index 44aba9736..24fd2d733 100644 --- a/src/song.c +++ b/src/song.c @@ -97,7 +97,7 @@ song_free(struct song *song) free(song); } -int +bool song_file_update(struct song *song) { struct decoder_plugin *plugin; @@ -120,9 +120,9 @@ song_file_update(struct song *song) song->tag = plugin->tag_dup(abs_path); if (song->tag == NULL || song->tag->time < 0) - return -1; + return false; - return 0; + return true; } char * -- cgit v1.2.3