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/python/api2_2x/Texture.c')
-rw-r--r--source/blender/python/api2_2x/Texture.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/source/blender/python/api2_2x/Texture.c b/source/blender/python/api2_2x/Texture.c
index 67120b5f6c6..1f2f54aadd3 100644
--- a/source/blender/python/api2_2x/Texture.c
+++ b/source/blender/python/api2_2x/Texture.c
@@ -2662,9 +2662,7 @@ static PyObject *Texture_getColorband( BPy_Texture * self)
int Texture_setColorband( BPy_Texture * self, PyObject * value)
{
- if (!self->texture->coba)
- self->texture->coba = MEM_callocN( sizeof(ColorBand), "colorband");
- return EXPP_Colorband_fromPyList( self->texture->coba, value );
+ return EXPP_Colorband_fromPyList( &self->texture->coba, value );
}
static PyObject *Texture_evaluate( BPy_Texture * self, PyObject * args )