Hi,
when calling :redraw in a BufAdd autocommand, this may cause several
E315 ml_get: invalid_lnum messages. Here is a backtrack
Here is a backtrace:
(gdb) bt
#0 ml_get_buf (buf=0xedf300, lnum=2, will_change=0) at memline.c:2469
#1 0x00000000004cf014 in plines_win_nofold (wp=0x897bf0, lnum=2) at
misc1.c:2008
#2 0x00000000004cefbf in plines_win_nofill (wp=0x897bf0, lnum=2, winheight=1)
at misc1.c:1991
#3 0x00000000004cef09 in plines_win (wp=0x897bf0, lnum=2, winheight=1) at
misc1.c:1958
#4 0x00000000004cf34f in plines_m_win (wp=0x897bf0, first=2, last=23) at
misc1.c:2118
#5 0x00000000005520b9 in win_update (wp=0x897bf0) at screen.c:1316
#6 0x0000000000551284 in update_screen (type=10) at screen.c:672
#7 0x0000000000478369 in ex_redraw (eap=0x7fffffffbbf0) at ex_docmd.c:9477
#8 0x000000000046d5c2 in do_one_cmd (cmdlinep=0x7fffffffc288, sourcing=1,
cstack=0x7fffffffbde0, fgetline=0x453496 <get_func_line>, cookie=0xde43f0) at
ex_docmd.c:2930
#9 0x000000000046a392 in do_cmdline (cmdline=0x0, fgetline=0x453496
<get_func_line>, cookie=0xde43f0, flags=7) at ex_docmd.c:1116
#10 0x0000000000452a0d in call_user_func (fp=0xd7d6d0, argcount=0,
argvars=0x7fffffffc7d0, rettv=0x7fffffffc990, firstline=1, lastline=1,
selfdict=0x0) at eval.c:23952
#11 0x0000000000438966 in call_func (funcname=0xde2440
"\200\375R131_update_tabline", len=21, rettv=0x7fffffffc990, argcount=0,
argvars=0x7fffffffc7d0, firstline=1, lastline=1, doesrange=0x7fffffffc98c,
evaluate=1, selfdict=0x0) at eval.c:8665
#12 0x000000000043850f in get_func_tv (name=0xde2440
"\200\375R131_update_tabline", len=21, rettv=0x7fffffffc990,
arg=0x7fffffffc9b0, firstline=1, lastline=1, doesrange=0x7fffffffc98c,
evaluate=1, selfdict=0x0) at eval.c:8494
#13 0x0000000000430b08 in ex_call (eap=0x7fffffffca80) at eval.c:3497
#14 0x000000000046d5c2 in do_one_cmd (cmdlinep=0x7fffffffd118, sourcing=1,
cstack=0x7fffffffcc70, fgetline=0x498786 <getnextac>, cookie=0x7fffffffd210) at
ex_docmd.c:2930
#15 0x000000000046a392 in do_cmdline (cmdline=0x0, fgetline=0x498786
<getnextac>, cookie=0x7fffffffd210, flags=7) at ex_docmd.c:1116
#16 0x0000000000498231 in apply_autocmds_group (event=EVENT_BUFADD,
fname=0xdddbe0
"/home/chrisbra/.vim/bundle/vim-airline/autoload/airline/highlighter.vim",
fname_io=0x0, force=0, group=-3, buf=0xedf300, eap=0x0) at fileio.c:9483
#17 0x00000000004979b6 in apply_autocmds (event=EVENT_BUFADD, fname=0x0,
fname_io=0x0, force=0, buf=0xedf300) at fileio.c:9033
#18 0x0000000000410bd5 in set_buflisted (on=1) at buffer.c:5805
#19 0x000000000045adff in do_ecmd (fnum=4, ffname=0x0, sfname=0x0, eap=0x0,
newlnum=1, flags=1, oldwin=0x897bf0) at ex_cmds.c:3615
#20 0x000000000045a555 in getfile (fnum=4, ffname=0x0, sfname=0x0, setpm=1,
lnum=1, forceit=0) at ex_cmds.c:3189
#21 0x0000000000409797 in buflist_getfile (n=4, lnum=1, options=5, forceit=0)
at buffer.c:2088
#22 0x000000000052654b in qf_jump (qi=0x884fc0 <ql_info>, dir=1, errornr=-1,
forceit=0) at quickfix.c:1798
#23 0x00000000005294b3 in ex_cnext (eap=0x7fffffffd6f0) at quickfix.c:3183
#24 0x000000000046d5c2 in do_one_cmd (cmdlinep=0x7fffffffdd88, sourcing=0,
cstack=0x7fffffffd8e0, fgetline=0x482de5 <getexline>, cookie=0x0) at
ex_docmd.c:2930
#25 0x000000000046a392 in do_cmdline (cmdline=0x0, fgetline=0x482de5
<getexline>, cookie=0x0, flags=0) at ex_docmd.c:1116
#26 0x00000000004f53bb in nv_colon (cap=0x7fffffffdeb0) at normal.c:5335
#27 0x00000000004ee851 in normal_cmd (oap=0x7fffffffdf80, toplevel=1) at
normal.c:1159
#28 0x00000000005f22a8 in main_loop (cmdwin=0, noexmode=0) at main.c:1351
#29 0x00000000005f1bfa in main (argc=2, argv=0x7fffffffe298) at main.c:1050
Here is a patch, that disables redrawing for BufAdd autocommands. I am not
sure, this is the correct solution however.
Best,
Christian
--
Rülpst im Schweinestall der Knecht, wird sogar den Schweinen schlecht.
--
--
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
---
You received this message because you are subscribed to the Google Groups
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.
diff --git a/src/buffer.c b/src/buffer.c
--- a/src/buffer.c
+++ b/src/buffer.c
@@ -5802,7 +5802,11 @@ set_buflisted(int on)
curbuf->b_p_bl = on;
#ifdef FEAT_AUTOCMD
if (on)
+ {
+ RedrawingDisabled++;
apply_autocmds(EVENT_BUFADD, NULL, NULL, FALSE, curbuf);
+ RedrawingDisabled--;
+ }
else
apply_autocmds(EVENT_BUFDELETE, NULL, NULL, FALSE, curbuf);
#endif