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:
Diffstat (limited to 'source/blender/editors/curve/editcurve.c')
-rw-r--r--source/blender/editors/curve/editcurve.c16
1 files changed, 9 insertions, 7 deletions
diff --git a/source/blender/editors/curve/editcurve.c b/source/blender/editors/curve/editcurve.c
index 06d88b16fa8..210f36ca074 100644
--- a/source/blender/editors/curve/editcurve.c
+++ b/source/blender/editors/curve/editcurve.c
@@ -3432,7 +3432,6 @@ static int convertspline(short type, Nurb *nu)
nu->type = CU_NURBS;
nu->orderu= 4;
nu->flagu &= CU_NURB_CYCLIC; /* disable all flags except for cyclic */
- nu->flagu |= CU_NURB_BEZIER;
nurbs_knot_calc_u(nu);
a= nu->pntsu*nu->pntsv;
bp= nu->bp;
@@ -6544,12 +6543,15 @@ Nurb *add_nurbs_primitive(bContext *C, float mat[4][4], int type, int newob)
BLI_assert(!"invalid nurbs type");
return NULL;
}
-
- /* always do: */
- nu->flag |= CU_SMOOTH;
-
- test2DNurb(nu);
-
+
+ BLI_assert(nu != NULL);
+
+ if(nu) { /* should always be set */
+ nu->flag |= CU_SMOOTH;
+
+ test2DNurb(nu);
+ }
+
return nu;
}