Index: source/blender/src/drawtext.c =================================================================== --- source/blender/src/drawtext.c (revision 10894) +++ source/blender/src/drawtext.c (working copy) @@ -940,6 +940,8 @@ char linenr[12]; float col[3]; int linecount = 0; + + if(!st) return; BIF_GetThemeColor3fv(TH_BACK, col); glClearColor(col[0], col[1], col[2], 0.0); @@ -1411,9 +1413,12 @@ short val= evt->val; char ascii= evt->ascii; SpaceText *st= curarea->spacedata.first; - Text *text= st->text; + Text *text; int do_draw=0, p; + if(!st) return; + text= st->text; + /* smartass code to prevent the CTRL/ALT events below from not working! */ if(G.qual & (LR_ALTKEY|LR_CTRLKEY)) if(!ispunct(ascii)) Index: source/blender/src/header_text.c =================================================================== --- source/blender/src/header_text.c (revision 10894) +++ source/blender/src/header_text.c (working copy) @@ -636,11 +636,14 @@ { uiBlock *block; SpaceText *st= curarea->spacedata.first; - Text *text= st->text; + Text *text; short xco, xmax; char naam[256]; - if (!st || st->spacetype != SPACE_TEXT) return; + if(!st) return; + if (st->spacetype != SPACE_TEXT) return; + + text= st->text; sprintf(naam, "header %d", curarea->headwin); block= uiNewBlock(&curarea->uiblocks, naam, UI_EMBOSS, UI_HELV, curarea->headwin);