aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/pipe.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/pipe.c b/src/pipe.c
index 54d10dd45..c3551265e 100644
--- a/src/pipe.c
+++ b/src/pipe.c
@@ -190,6 +190,8 @@ tail_chunk(size_t frame_size)
chunk = music_pipe_get_chunk(music_pipe.end);
assert(chunk->length <= sizeof(chunk->data));
+ assert((chunk->length % frame_size) == 0);
+
if (chunk->length + frame_size > sizeof(chunk->data)) {
/* this chunk is full; allocate a new chunk */
next = successor(music_pipe.end);