diff options
author | Kent Mein <mein@cs.umn.edu> | 2009-06-05 07:40:58 +0400 |
---|---|---|
committer | Kent Mein <mein@cs.umn.edu> | 2009-06-05 07:40:58 +0400 |
commit | d585a201e1f1494888c75f4391b30ae7e60d65d7 (patch) | |
tree | 58d5bbf039c93a9210349a029475ebae3aee7a7c /source/blender/imbuf | |
parent | 52b7c157a0c0d0bd1836be3149c683abf8bd1743 (diff) |
coverity issue CID: 484
Checker: REVERSE_INULL (help)
File: base/src/source/blender/imbuf/intern/anim.c
Function: IMB_anim_absolute
Description: Pointer "anim" dereferenced before NULL check
again moving init code after check to valid pointer.
Kent
Diffstat (limited to 'source/blender/imbuf')
-rw-r--r-- | source/blender/imbuf/intern/anim.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/source/blender/imbuf/intern/anim.c b/source/blender/imbuf/intern/anim.c index 42fe47cc5e9..3e09eb5e306 100644 --- a/source/blender/imbuf/intern/anim.c +++ b/source/blender/imbuf/intern/anim.c @@ -1046,10 +1046,11 @@ struct ImBuf * IMB_anim_absolute(struct anim * anim, int position) { char head[256], tail[256]; unsigned short digits; int pic; - int filter_y = (anim->ib_flags & IB_animdeinterlace); - + int filter_y; if (anim == NULL) return(0); + filter_y = (anim->ib_flags & IB_animdeinterlace); + if (anim->curtype == 0) { ibuf = anim_getnew(anim); if (ibuf == NULL) { |