vss: need_audio_header(): Change return value to bool.
authorAndre Noll <maan@systemlinux.org>
Sat, 7 Aug 2010 16:33:04 +0000 (18:33 +0200)
committerAndre Noll <maan@systemlinux.org>
Sun, 31 Oct 2010 11:06:57 +0000 (12:06 +0100)
Obviously an equivalent transformation.

vss.c

diff --git a/vss.c b/vss.c
index 383a8fda0710653c28c5853c2b8e7949b9b45b54..2e952eb4c6a1b0202a69ae79e0bab9a153fd0b04 100644 (file)
--- a/vss.c
+++ b/vss.c
@@ -215,20 +215,20 @@ static void write_fec_header(struct fec_client *fc, struct vss_task *vsst)
        memset(buf + 24, 0, 7);
 }
 
-static int need_audio_header(struct fec_client *fc, struct vss_task *vsst)
+static bool need_audio_header(struct fec_client *fc, struct vss_task *vsst)
 {
        if (!mmd->current_chunk) {
                tv_add(now, &vsst->header_interval, &fc->next_header_time);
-               return 0;
+               return false;
        }
        if (!vsst->header_buf)
-               return 0;
-       if (!vsst->header_len)
-               return 0;
+               return false;
+       if (vsst->header_len == 0)
+               return false;
        if (fc->group.num && tv_diff(&fc->next_header_time, now, NULL) > 0)
-               return 0;
+               return false;
        tv_add(now, &vsst->header_interval, &fc->next_header_time);
-       return 1;
+       return true;
 }
 
 static int num_slices(long unsigned bytes, int mps, int rs)