diff options
author | Gabriel Dume <gabriel.ddx84@gmail.com> | 2014-08-14 16:31:24 -0400 |
---|---|---|
committer | Diego Biurrun <diego@biurrun.de> | 2014-08-15 03:18:18 -0700 |
commit | f929ab0569ff31ed5a59b0b0adb7ce09df3fca39 (patch) | |
tree | 5b93402fb37cc43b899451a5d2b65bfc03d7887b /libavcodec/rv10.c | |
parent | efd26bedec9a345a5960dbfcbaec888418f2d4e6 (diff) | |
download | ffmpeg-f929ab0569ff31ed5a59b0b0adb7ce09df3fca39.tar.gz |
cosmetics: Write NULL pointer equality checks more compactly
Signed-off-by: Diego Biurrun <diego@biurrun.de>
Diffstat (limited to 'libavcodec/rv10.c')
-rw-r--r-- | libavcodec/rv10.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/libavcodec/rv10.c b/libavcodec/rv10.c index 1787a7e78e..2b571c9ba2 100644 --- a/libavcodec/rv10.c +++ b/libavcodec/rv10.c @@ -326,7 +326,7 @@ static int rv20_decode_picture_header(RVDecContext *rv) return AVERROR_INVALIDDATA; } - if (s->last_picture_ptr == NULL && s->pict_type == AV_PICTURE_TYPE_B) { + if (!s->last_picture_ptr && s->pict_type == AV_PICTURE_TYPE_B) { av_log(s->avctx, AV_LOG_ERROR, "early B-frame\n"); return AVERROR_INVALIDDATA; } @@ -557,7 +557,7 @@ static int rv10_decode_packet(AVCodecContext *avctx, const uint8_t *buf, return AVERROR_INVALIDDATA; } - if ((s->mb_x == 0 && s->mb_y == 0) || s->current_picture_ptr == NULL) { + if ((s->mb_x == 0 && s->mb_y == 0) || !s->current_picture_ptr) { // FIXME write parser so we always have complete frames? if (s->current_picture_ptr) { ff_er_frame_end(&s->er); |