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:
authorCampbell Barton <ideasman42@gmail.com>2010-04-18 13:12:18 +0400
committerCampbell Barton <ideasman42@gmail.com>2010-04-18 13:12:18 +0400
commit45441c07d4609493aecf265b64ad0c108722e9db (patch)
tree47ccd4e9dff0d6521181a3997c7fdc49a651eda3 /source/blender/editors/space_text
parent01e2de7c538d4b0bbddefae7f5272af93a30319b (diff)
various minor fixes
- collada export would run MEM_freeN on an un-initialized pointer in some cases. - makesrna was missing a call to close a file. - text cursor update function was missing a NULL check for st->text. - possible (unlikely) un-initialized return value for bge python lamp.type, set error instead. - possible (unlikely) missing NULL terminator with strncpy for ffmpeg.
Diffstat (limited to 'source/blender/editors/space_text')
-rw-r--r--source/blender/editors/space_text/text_draw.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/source/blender/editors/space_text/text_draw.c b/source/blender/editors/space_text/text_draw.c
index 4a73340d719..510429140d7 100644
--- a/source/blender/editors/space_text/text_draw.c
+++ b/source/blender/editors/space_text/text_draw.c
@@ -1318,11 +1318,13 @@ void text_update_cursor_moved(bContext *C)
{
ScrArea *sa= CTX_wm_area(C);
SpaceText *st= CTX_wm_space_text(C);
- Text *text= st->text;
+ Text *text;
ARegion *ar;
int i, x, winx= 0;
- if(!st) return;
+ if(!st || !st->text || st->text->curl) return;
+
+ text= st->text;
for(ar=sa->regionbase.first; ar; ar= ar->next)
if(ar->regiontype==RGN_TYPE_WINDOW)
@@ -1330,8 +1332,6 @@ void text_update_cursor_moved(bContext *C)
winx -= TXT_SCROLL_WIDTH;
- if(!text || !text->curl) return;
-
text_update_character_width(st);
i= txt_get_span(text->lines.first, text->sell);