diff options
author | Campbell Barton <ideasman42@gmail.com> | 2011-07-26 17:33:04 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2011-07-26 17:33:04 +0400 |
commit | ca293c835f15e8b0d19116456c75ba971f02e16b (patch) | |
tree | d61701c08e9622add0d1ceff6d4c5ce4d5de2fe1 /source/blender/editors/transform | |
parent | 40353fe0d841e006d11ad5833eaedbc93fc0d608 (diff) |
correct misc warnings
Diffstat (limited to 'source/blender/editors/transform')
-rw-r--r-- | source/blender/editors/transform/transform_snap.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/source/blender/editors/transform/transform_snap.c b/source/blender/editors/transform/transform_snap.c index d9d9b0f9102..a4307ea336d 100644 --- a/source/blender/editors/transform/transform_snap.c +++ b/source/blender/editors/transform/transform_snap.c @@ -1944,6 +1944,11 @@ static void applyGrid(TransInfo *t, float *val, int max_index, float fac[3], Gea int i; float asp[3] = {1.0f, 1.0f, 1.0f}; // TODO: Remove hard coded limit here (3) + if(max_index > 3) { + printf("applyGrid: invalid index %d, clamping\n", max_index); + max_index= 3; + } + // Early bailing out if no need to snap if (fac[action] == 0.0f) return; |