Fix write past end of array in recent texture sampling refactoring commit, and

a small warning for double const keyword.
This commit is contained in:
Brecht Van Lommel 2013-03-13 14:19:55 +00:00
parent 4e86946c2b
commit 136738029e
2 changed files with 2 additions and 2 deletions

@ -539,7 +539,7 @@ float BKE_brush_sample_tex_3D(const Scene *scene, Brush *br,
float point_2d[2] = {point[0], point[1]};
float x = 0.0f, y = 0.0f; /* Quite warnings */
float radius = 1.0f; /* Quite warnings */
float co[2];
float co[3];
if (mtex->brush_map_mode == MTEX_MAP_MODE_VIEW) {
/* keep coordinates relative to mouse */

@ -2229,7 +2229,7 @@ static int mouse_weight_paint_vertex_select(bContext *C, const int mval[2], shor
/* ****** Mouse Select ****** */
static int view3d_select_invoke(bContext *C, wmOperator *op, const const wmEvent *event)
static int view3d_select_invoke(bContext *C, wmOperator *op, const wmEvent *event)
{
Object *obedit = CTX_data_edit_object(C);
Object *obact = CTX_data_active_object(C);