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
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2013-07-13 20:25:47 +0400
committerCampbell Barton <ideasman42@gmail.com>2013-07-13 20:25:47 +0400
commitb7396654e181b84985ef54b7afce252b2584e69a (patch)
treefbd3ca8df04e9fd6e933a3a3a06df7daf89fc0c0 /source/blender/blenkernel/intern
parent4a39a4a92afe6d516e6e94ca4f81349aefbb1cc7 (diff)
fix for bad NULL check in bmo_connect_pair, also remove duplicate checks in if statements and redundant initialization vars.
Diffstat (limited to 'source/blender/blenkernel/intern')
-rw-r--r--source/blender/blenkernel/intern/brush.c4
-rw-r--r--source/blender/blenkernel/intern/constraint.c2
-rw-r--r--source/blender/blenkernel/intern/tracking.c2
3 files changed, 4 insertions, 4 deletions
diff --git a/source/blender/blenkernel/intern/brush.c b/source/blender/blenkernel/intern/brush.c
index 307dbc64847..8130f6e646c 100644
--- a/source/blender/blenkernel/intern/brush.c
+++ b/source/blender/blenkernel/intern/brush.c
@@ -539,7 +539,7 @@ float BKE_brush_sample_tex_3D(const Scene *scene, Brush *br,
else if (mtex->brush_map_mode == MTEX_MAP_MODE_STENCIL) {
float rotation = -mtex->rot;
float point_2d[2] = {point[0], point[1]};
- float x = 0.0f, y = 0.0f; /* Quite warnings */
+ float x, y;
float co[3];
x = point_2d[0] - br->stencil_pos[0];
@@ -658,7 +658,7 @@ float BKE_brush_sample_masktex(const Scene *scene, Brush *br,
if (mtex->brush_map_mode == MTEX_MAP_MODE_STENCIL) {
float rotation = -mtex->rot;
float point_2d[2] = {point[0], point[1]};
- float x = 0.0f, y = 0.0f; /* Quite warnings */
+ float x, y;
float co[3];
x = point_2d[0] - br->mask_stencil_pos[0];
diff --git a/source/blender/blenkernel/intern/constraint.c b/source/blender/blenkernel/intern/constraint.c
index 0cd13d528d5..c78038c0f66 100644
--- a/source/blender/blenkernel/intern/constraint.c
+++ b/source/blender/blenkernel/intern/constraint.c
@@ -2519,7 +2519,7 @@ static void distlimit_evaluate(bConstraint *con, bConstraintOb *cob, ListBase *t
/* only evaluate if there is a target */
if (VALID_CONS_TARGET(ct)) {
- float dvec[3], dist = 0.0f, sfac = 1.0f;
+ float dvec[3], dist, sfac = 1.0f;
short clamp_surf = 0;
/* calculate our current distance from the target */
diff --git a/source/blender/blenkernel/intern/tracking.c b/source/blender/blenkernel/intern/tracking.c
index 8141fc8aaa1..2c561dd4472 100644
--- a/source/blender/blenkernel/intern/tracking.c
+++ b/source/blender/blenkernel/intern/tracking.c
@@ -3455,7 +3455,7 @@ static bool check_point_in_stroke(bGPDstroke *stroke, float x, float y)
prev = i;
}
- return count % 2 ? true : false;
+ return (count % 2) ? true : false;
}
/* Check whether point is inside any stroke of grease pencil layer. */