exe "norm! v\<C-W>:\<C-U>echo v:version"
endfunc
+func Test_access_freed_mem()
+ " This was accessing freed memory
+ au * 0 vs xxx
+ arg 0
+ argadd
+ all
+ all
+ au!
+ bwipe xxx
+endfunc
+
" vim: shiftwidth=2 sts=2 expandtab
if (frp2->fr_win != NULL)
frp2->fr_win->w_frame = frp2->fr_parent;
frp = frp2->fr_parent;
+ if (topframe->fr_child == frp2)
+ topframe->fr_child = frp;
vim_free(frp2);
frp2 = frp->fr_parent;
break;
}
}
+ if (topframe->fr_child == frp)
+ topframe->fr_child = frp2;
vim_free(frp);
}
}
topframe = curwin->w_frame;
topframe->fr_width = Columns;
topframe->fr_height = Rows - p_ch;
- topframe->fr_win = curwin;
return OK;
}
if (frp->fr_prev != NULL)
frp->fr_prev->fr_next = frp->fr_next;
else
+ {
frp->fr_parent->fr_child = frp->fr_next;
+ /* special case: topframe->fr_child == frp */
+ if (topframe->fr_child == frp)
+ topframe->fr_child = frp->fr_next;
+ }
if (frp->fr_next != NULL)
frp->fr_next->fr_prev = frp->fr_prev;
}