Browse Source

mmf: simplify code by using FFMIN

Signed-off-by: Paul B Mahol <onemda@gmail.com>
tags/n1.1
Paul B Mahol 12 years ago
parent
commit
05b02e9c0f
1 changed files with 1 additions and 3 deletions
  1. +1
    -3
      libavformat/mmf.c

+ 1
- 3
libavformat/mmf.c View File

@@ -271,9 +271,7 @@ static int mmf_read_packet(AVFormatContext *s,
if (url_feof(s->pb) || !mmf->data_size)
return AVERROR_EOF;

size = MAX_SIZE;
if(size > mmf->data_size)
size = mmf->data_size;
size = FFMIN(MAX_SIZE, mmf->data_size);

ret = av_get_packet(s->pb, pkt, size);
if (ret < 0)


Loading…
Cancel
Save