summaryrefslogtreecommitdiff
path: root/libavcodec/mpeg12dec.c
diff options
context:
space:
mode:
authorGabriel Dume <gabriel.ddx84@gmail.com>2014-08-14 16:31:24 -0400
committerDiego Biurrun <diego@biurrun.de>2014-08-15 03:18:18 -0700
commitf929ab0569ff31ed5a59b0b0adb7ce09df3fca39 (patch)
tree5b93402fb37cc43b899451a5d2b65bfc03d7887b /libavcodec/mpeg12dec.c
parentefd26bedec9a345a5960dbfcbaec888418f2d4e6 (diff)
cosmetics: Write NULL pointer equality checks more compactly
Signed-off-by: Diego Biurrun <diego@biurrun.de>
Diffstat (limited to 'libavcodec/mpeg12dec.c')
-rw-r--r--libavcodec/mpeg12dec.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/libavcodec/mpeg12dec.c b/libavcodec/mpeg12dec.c
index 5a875c2518..2b86ea87fe 100644
--- a/libavcodec/mpeg12dec.c
+++ b/libavcodec/mpeg12dec.c
@@ -2488,7 +2488,7 @@ static int decode_chunks(AVCodecContext *avctx, AVFrame *picture,
return -1;
}
- if (s2->last_picture_ptr == NULL) {
+ if (!s2->last_picture_ptr) {
/* Skip B-frames if we do not have reference frames and
* GOP is not closed. */
if (s2->pict_type == AV_PICTURE_TYPE_B) {
@@ -2500,7 +2500,7 @@ static int decode_chunks(AVCodecContext *avctx, AVFrame *picture,
}
if (s2->pict_type == AV_PICTURE_TYPE_I)
s->sync = 1;
- if (s2->next_picture_ptr == NULL) {
+ if (!s2->next_picture_ptr) {
/* Skip P-frames if we do not have a reference frame or
* we have an invalid header. */
if (s2->pict_type == AV_PICTURE_TYPE_P && !s->sync) {