diff options
author | Martin Storsjö <martin@martin.st> | 2015-02-25 23:33:24 +0200 |
---|---|---|
committer | Martin Storsjö <martin@martin.st> | 2015-02-28 22:53:51 +0200 |
commit | 1fc64e2e07787bbca82a72c146588e850e6d098a (patch) | |
tree | 4191967dbe46b43b7dc43acd394256412671a7b1 /libavformat | |
parent | 0662440b991361fdb5e732712d997a73e4692e34 (diff) | |
download | ffmpeg-1fc64e2e07787bbca82a72c146588e850e6d098a.tar.gz |
rtpenc: Write conditional statements on separate lines
Intentionally keeping some conditional statements on single lines
in rtpenc_h263.c.
Signed-off-by: Martin Storsjö <martin@martin.st>
Diffstat (limited to 'libavformat')
-rw-r--r-- | libavformat/rtpenc.c | 3 | ||||
-rw-r--r-- | libavformat/rtpenc_xiph.c | 6 |
2 files changed, 6 insertions, 3 deletions
diff --git a/libavformat/rtpenc.c b/libavformat/rtpenc.c index b306a4cd9a..cfa5f348fd 100644 --- a/libavformat/rtpenc.c +++ b/libavformat/rtpenc.c @@ -220,7 +220,8 @@ static int rtp_write_header(AVFormatContext *s1) break; case AV_CODEC_ID_VORBIS: case AV_CODEC_ID_THEORA: - if (!s->max_frames_per_packet) s->max_frames_per_packet = 15; + if (!s->max_frames_per_packet) + s->max_frames_per_packet = 15; s->max_frames_per_packet = av_clip(s->max_frames_per_packet, 1, 15); s->max_payload_size -= 6; // ident+frag+tdt/vdt+pkt_num+pkt_length s->num_frames = 0; diff --git a/libavformat/rtpenc_xiph.c b/libavformat/rtpenc_xiph.c index 07086b1a12..def3bc5ee5 100644 --- a/libavformat/rtpenc_xiph.c +++ b/libavformat/rtpenc_xiph.c @@ -81,14 +81,16 @@ void ff_rtp_send_xiph(AVFormatContext *s1, const uint8_t *buff, int size) } // buffer current frame to send later - if (0 == s->num_frames) s->timestamp = s->cur_timestamp; + if (0 == s->num_frames) + s->timestamp = s->cur_timestamp; s->num_frames++; // Set packet header. Normally, this is OR'd with frag and xdt, // but those are zero, so omitted here *q++ = s->num_frames; - if (s->num_frames > 1) q = s->buf_ptr; // jump ahead if needed + if (s->num_frames > 1) + q = s->buf_ptr; // jump ahead if needed *q++ = (size >> 8) & 0xff; *q++ = size & 0xff; memcpy(q, buff, size); |