aboutsummaryrefslogtreecommitdiffstats
path: root/src/pipe.h
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2010-11-05 18:34:06 +0100
committerMax Kellermann <max@duempel.org>2010-11-05 18:40:23 +0100
commitc594afeee70b29cc88e337a3b8fbd2a39ac37822 (patch)
tree0823a21db5b09023f5ffa296c464f099f627916a /src/pipe.h
parent32d10eedbde70ef3d5ae0f1567cee3e25e4f9993 (diff)
downloadmpd-c594afeee70b29cc88e337a3b8fbd2a39ac37822.tar.gz
mpd-c594afeee70b29cc88e337a3b8fbd2a39ac37822.tar.xz
mpd-c594afeee70b29cc88e337a3b8fbd2a39ac37822.zip
pipe: add helper function music_pipe_empty()
Diffstat (limited to '')
-rw-r--r--src/pipe.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/pipe.h b/src/pipe.h
index f91fc1c7f..2825b320a 100644
--- a/src/pipe.h
+++ b/src/pipe.h
@@ -99,4 +99,10 @@ music_pipe_push(struct music_pipe *mp, struct music_chunk *chunk);
unsigned
music_pipe_size(const struct music_pipe *mp);
+static inline bool
+music_pipe_empty(const struct music_pipe *mp)
+{
+ return music_pipe_size(mp) == 0;
+}
+
#endif