Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/source
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2012-04-30 15:08:53 +0400
committerCampbell Barton <ideasman42@gmail.com>2012-04-30 15:08:53 +0400
commit5255c23cb7a4ce63410e92a22ebdb58829c48f1a (patch)
treed00a947716450ea09a1040184dba4c8b429e6907 /source
parent8f3ed0501e78d62b2b507d5befb454a5c98375d2 (diff)
code cleanup: clang warning - use of a pointer before checking its NULL.
Diffstat (limited to 'source')
-rw-r--r--source/blender/editors/space_clip/space_clip.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/source/blender/editors/space_clip/space_clip.c b/source/blender/editors/space_clip/space_clip.c
index 4044568b70d..f64d2ba90cb 100644
--- a/source/blender/editors/space_clip/space_clip.c
+++ b/source/blender/editors/space_clip/space_clip.c
@@ -779,11 +779,12 @@ static void clip_refresh(const bContext *C, ScrArea *sa)
}
else {
/* store graph region align */
- if (ar_preview->alignment == RGN_ALIGN_TOP)
- sc->runtime_flag &= ~SC_GRAPH_BOTTOM;
- else if (ar_preview->alignment == RGN_ALIGN_BOTTOM)
- sc->runtime_flag |= SC_GRAPH_BOTTOM;
-
+ if (ar_preview) {
+ if (ar_preview->alignment == RGN_ALIGN_TOP)
+ sc->runtime_flag &= ~SC_GRAPH_BOTTOM;
+ else if (ar_preview->alignment == RGN_ALIGN_BOTTOM)
+ sc->runtime_flag |= SC_GRAPH_BOTTOM;
+ }
if (ar_preview && !(ar_preview->flag & RGN_FLAG_HIDDEN)) {
ar_preview->flag |= RGN_FLAG_HIDDEN;
ar_preview->v2d.flag &= ~V2D_IS_INITIALISED;