From f000ce6fbad75de067a076bc12e4c3403b911eed Mon Sep 17 00:00:00 2001 From: Ken Hughes Date: Sun, 2 Jul 2006 21:37:06 +0000 Subject: ===Python API=== Bugfix: key curve names compared using strncmp instead of strcmp, resulting in wrong comparisons. --- source/blender/python/api2_2x/Ipo.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'source/blender/python') diff --git a/source/blender/python/api2_2x/Ipo.c b/source/blender/python/api2_2x/Ipo.c index 225908e2ed2..1ad9f45ee0e 100644 --- a/source/blender/python/api2_2x/Ipo.c +++ b/source/blender/python/api2_2x/Ipo.c @@ -525,7 +525,7 @@ static short lookup_curve_name( char *str, int blocktype, int channel ) char *name = lookup_name ( *adrcodes ); /* if not a texture channel, just return the adrcode */ - if( !strncmp( str, name, strlen( name ) ) ) { + if( !strcmp( str, name ) ) { if( channel == -1 || *adrcodes < MA_MAP1 ) return (short)*adrcodes; @@ -552,7 +552,7 @@ static short lookup_curve_key( char *str, Ipo *ipo ) /* look for a matching string, get the adrcode */ for( block = keyiter->block.first; block; block = block->next ) - if( !strncmp( str, block->name, strlen( block->name) ) ) + if( !strcmp( str, block->name ) ) return block->adrcode; /* no match; no addr code */ -- cgit v1.2.3