From e4b20c3d2a1754f20cee544ea400c3ba522c9efd Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Sat, 6 Jun 2009 11:26:43 +0000 Subject: [PATCH] Setting the directories and files is buggy still, but this should prevent some simple crashes, file was 80 chars long but it let the text input type in 160 chars. --- source/blender/src/buttons_scene.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/source/blender/src/buttons_scene.c b/source/blender/src/buttons_scene.c index f99ac47b2c5..c0ba5469c9a 100644 --- a/source/blender/src/buttons_scene.c +++ b/source/blender/src/buttons_scene.c @@ -1206,7 +1206,7 @@ static void seq_panel_proxy() uiDefBut(block, TEX, B_SEQ_BUT_RELOAD, "Dir: ", 30,120,220,20, last_seq->strip->proxy->dir, - 0.0, 160.0, 100, 0, ""); + 0.0, (float)sizeof(last_seq->strip->proxy->dir), 100, 0, ""); } if (last_seq->flag & SEQ_USE_PROXY_CUSTOM_FILE) { uiDefIconBut(block, BUT, B_SEQ_SEL_PROXY_FILE, @@ -1218,7 +1218,7 @@ static void seq_panel_proxy() uiDefBut(block, TEX, B_SEQ_BUT_RELOAD, "File: ", 30,100,220,20, last_seq->strip->proxy->file, - 0.0, 160.0, 100, 0, ""); + 0.0, (float)sizeof(last_seq->strip->proxy->file), 100, 0, ""); } } @@ -1307,7 +1307,7 @@ void sequencer_panels() static void sel_proxy_dir(char *name) { Sequence *last_seq = get_last_seq(); - strcpy(last_seq->strip->proxy->dir, name); + BLI_strncpy(last_seq->strip->proxy->dir, name, sizeof(last_seq->strip->proxy->dir)); allqueue(REDRAWBUTSSCENE, 0);