X-Git-Url: http://git.tuebingen.mpg.de/?p=paraslash.git;a=blobdiff_plain;f=vss.c;h=2068563cf557d9531b84f508cb869d16120e584c;hp=ba6f7c4c655134d11d79e6411ab92d63b4efd160;hb=e9ac00becb2aba5bbbf51b4803b81b10ed4d6788;hpb=1c8226eae0e976d940366cd10bd708d8e4d0bca5 diff --git a/vss.c b/vss.c index ba6f7c4c..2068563c 100644 --- a/vss.c +++ b/vss.c @@ -12,7 +12,6 @@ */ #include -#include #include #include "para.h" @@ -542,6 +541,7 @@ static int setup_next_fec_group(struct fec_client *fc, struct vss_task *vsst) /* setup header slices */ buf = vsst->header_buf; for (i = 0; i < g->num_header_slices; i++) { + uint32_t payload_size; if (buf + g->slice_bytes <= vsst->header_buf + vsst->header_len) { fc->src_data[i] = (const unsigned char *)buf; buf += g->slice_bytes; @@ -552,8 +552,7 @@ static int setup_next_fec_group(struct fec_client *fc, struct vss_task *vsst) * goes beyond the buffer. This slice will not be fully * used. */ - uint32_t payload_size = vsst->header_buf - + vsst->header_len - buf; + payload_size = vsst->header_buf + vsst->header_len - buf; memcpy(fc->extra_header_buf, buf, payload_size); if (payload_size < g->slice_bytes) memset(fc->extra_header_buf + payload_size, 0,