diff options
author | Campbell Barton <ideasman42@gmail.com> | 2010-12-03 20:05:21 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2010-12-03 20:05:21 +0300 |
commit | 263830f0004481cd4921f03f4242d7c80794b08d (patch) | |
tree | 30b512a06df2e619681ecacf97faee69e46913f8 /source/blender/python/intern/bpy_props.c | |
parent | 7c86a1a95cbc643fdbbf8c28f0422face8a15a19 (diff) |
Enabled GCC -Wwrite-strings warning for CMake and replaced many 'char's for 'const char's,.
Only one functional change where Transform orientations passed "" to BIF_createTransformOrientation() which could then have the value written into.
Diffstat (limited to 'source/blender/python/intern/bpy_props.c')
-rw-r--r-- | source/blender/python/intern/bpy_props.c | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/source/blender/python/intern/bpy_props.c b/source/blender/python/intern/bpy_props.c index 6cf5e8e40c3..b7192f7395b 100644 --- a/source/blender/python/intern/bpy_props.c +++ b/source/blender/python/intern/bpy_props.c @@ -183,8 +183,8 @@ static PyObject *BPy_BoolProperty(PyObject *self, PyObject *args, PyObject *kw) BPY_PROPDEF_HEAD(BoolProperty) if(srna) { - static char *kwlist[] = {"attr", "name", "description", "default", "options", "subtype", NULL}; - char *id=NULL, *name="", *description=""; + static const char *kwlist[] = {"attr", "name", "description", "default", "options", "subtype", NULL}; + const char *id=NULL, *name="", *description=""; int id_len; int def=0; PropertyRNA *prop; @@ -229,7 +229,7 @@ static PyObject *BPy_BoolVectorProperty(PyObject *self, PyObject *args, PyObject if(srna) { static const char *kwlist[] = {"attr", "name", "description", "default", "options", "subtype", "size", NULL}; - char *id=NULL, *name="", *description=""; + const char *id=NULL, *name="", *description=""; int id_len; int def[PYRNA_STACK_ARRAY]={0}; int size=3; @@ -286,7 +286,7 @@ static PyObject *BPy_IntProperty(PyObject *self, PyObject *args, PyObject *kw) if(srna) { static const char *kwlist[] = {"attr", "name", "description", "default", "min", "max", "soft_min", "soft_max", "step", "options", "subtype", NULL}; - char *id=NULL, *name="", *description=""; + const char *id=NULL, *name="", *description=""; int id_len; int min=INT_MIN, max=INT_MAX, soft_min=INT_MIN, soft_max=INT_MAX, step=1, def=0; PropertyRNA *prop; @@ -332,7 +332,7 @@ static PyObject *BPy_IntVectorProperty(PyObject *self, PyObject *args, PyObject if(srna) { static const char *kwlist[] = {"attr", "name", "description", "default", "min", "max", "soft_min", "soft_max", "step", "options", "subtype", "size", NULL}; - char *id=NULL, *name="", *description=""; + const char *id=NULL, *name="", *description=""; int id_len; int min=INT_MIN, max=INT_MAX, soft_min=INT_MIN, soft_max=INT_MAX, step=1, def[PYRNA_STACK_ARRAY]={0}; int size=3; @@ -392,7 +392,7 @@ static PyObject *BPy_FloatProperty(PyObject *self, PyObject *args, PyObject *kw) if(srna) { static const char *kwlist[] = {"attr", "name", "description", "default", "min", "max", "soft_min", "soft_max", "step", "precision", "options", "subtype", "unit", NULL}; - char *id=NULL, *name="", *description=""; + const char *id=NULL, *name="", *description=""; int id_len; float min=-FLT_MAX, max=FLT_MAX, soft_min=-FLT_MAX, soft_max=FLT_MAX, step=3, def=0.0f; int precision= 2; @@ -446,7 +446,7 @@ static PyObject *BPy_FloatVectorProperty(PyObject *self, PyObject *args, PyObjec if(srna) { static const char *kwlist[] = {"attr", "name", "description", "default", "min", "max", "soft_min", "soft_max", "step", "precision", "options", "subtype", "size", NULL}; - char *id=NULL, *name="", *description=""; + const char *id=NULL, *name="", *description=""; int id_len; float min=-FLT_MAX, max=FLT_MAX, soft_min=-FLT_MAX, soft_max=FLT_MAX, step=3, def[PYRNA_STACK_ARRAY]={0.0f}; int precision= 2, size=3; @@ -503,7 +503,7 @@ static PyObject *BPy_StringProperty(PyObject *self, PyObject *args, PyObject *kw if(srna) { static const char *kwlist[] = {"attr", "name", "description", "default", "maxlen", "options", "subtype", NULL}; - char *id=NULL, *name="", *description="", *def=""; + const char *id=NULL, *name="", *description="", *def=""; int id_len; int maxlen=0; PropertyRNA *prop; @@ -594,7 +594,7 @@ static PyObject *BPy_EnumProperty(PyObject *self, PyObject *args, PyObject *kw) if(srna) { static const char *kwlist[] = {"attr", "items", "name", "description", "default", "options", NULL}; - char *id=NULL, *name="", *description="", *def=""; + const char *id=NULL, *name="", *description="", *def=""; int id_len; int defvalue=0; PyObject *items= Py_None; @@ -662,7 +662,7 @@ static PyObject *BPy_PointerProperty(PyObject *self, PyObject *args, PyObject *k if(srna) { static const char *kwlist[] = {"attr", "type", "name", "description", "options", NULL}; - char *id=NULL, *name="", *description=""; + const char *id=NULL, *name="", *description=""; int id_len; PropertyRNA *prop; StructRNA *ptype; @@ -706,7 +706,7 @@ static PyObject *BPy_CollectionProperty(PyObject *self, PyObject *args, PyObject if(srna) { static const char *kwlist[] = {"attr", "type", "name", "description", "options", NULL}; - char *id=NULL, *name="", *description=""; + const char *id=NULL, *name="", *description=""; int id_len; PropertyRNA *prop; StructRNA *ptype; |