# HG changeset patch # User benoit # Date 1276149606 0 # Node ID f533ea0b236fe5d4c4b5fe50809581da213600e6 # Parent fb5a6e98aa1c07cc258ac3413b2a6e14e24a422b Cosmetics: use and place braces correctly in if ... else statements. diff -r fb5a6e98aa1c -r f533ea0b236f h264_mp4toannexb_bsf.c --- a/h264_mp4toannexb_bsf.c Thu Jun 10 05:59:22 2010 +0000 +++ b/h264_mp4toannexb_bsf.c Thu Jun 10 06:00:06 2010 +0000 @@ -43,9 +43,9 @@ if (sps_pps) memcpy(*poutbuf+offset, sps_pps, sps_pps_size); memcpy(*poutbuf+sps_pps_size+nal_header_size+offset, in, in_size); - if (!offset) + if (!offset) { AV_WB32(*poutbuf+sps_pps_size, 1); - else { + } else { (*poutbuf+offset+sps_pps_size)[0] = (*poutbuf+offset+sps_pps_size)[1] = 0; (*poutbuf+offset+sps_pps_size)[2] = 1; } @@ -127,11 +127,11 @@ if (buf + ctx->length_size > buf_end) goto fail; - if (ctx->length_size == 1) + if (ctx->length_size == 1) { nal_size = buf[0]; - else if (ctx->length_size == 2) + } else if (ctx->length_size == 2) { nal_size = AV_RB16(buf); - else + } else nal_size = AV_RB32(buf); buf += ctx->length_size; @@ -147,8 +147,7 @@ buf, nal_size) < 0) goto fail; ctx->first_idr = 0; - } - else { + } else { if (alloc_and_copy(poutbuf, poutbuf_size, NULL, 0, buf, nal_size) < 0)