On Sun, Jul 9, 2017 at 1:19 PM, Bram Moolenaar <b...@moolenaar.net> wrote:
> > Aron Griffis wrote: > > > On Saturday, July 8, 2017 at 4:38:36 PM UTC-4, Bram Moolenaar wrote: > > > Patch 8.0.0702 > > > Problem: An error in a timer can make Vim unusable. > > > Solution: Don't set the error flag or exception from a timer. Stop > a timer > > > if it causes an error 3 out of 3 times. Discard an > exception > > > caused inside a timer. > > > Files: src/ex_cmds2.c, src/structs.h, src/testdir/test_timers.vim, > > > runtime/doc/eval.txt > > > > This patch is causing segfaults for me. I've built with and without it > to verify. > > > > I have a timer to check a couple files and update my color scheme when > they change. I haven't tried to narrow down any specific lines yet, but > when TryTheme actually triggers then vim segfaults immediately. Maybe > because of the try/catch? > > > > Here's the code from my vimrc: > > [..] > > I haven't managed to reproduce it. Can you run Vim in a debugger and > see the call stack? > > Sorry for not including the backtrace earlier. I imagined you'd look at the combination of the 702 patch and my vimrc and the problem would jump out—didn't mean to make extra work for folks trying to repro the segfault. (gdb) bt #0 0x00007ffff6af4fd6 in free () from /lib64/libc.so.6 #1 0x0000555555611cc2 in discard_exception (excp=0x555555dec8e0, was_finished=0) at ex_eval.c:633 #2 0x00005555556127e2 in discard_current_exception () at ex_eval.c:643 #3 0x00005555555fa7cb in check_due_timer () at ex_cmds2.c:1239 #4 0x000055555569dd75 in WaitForChar (msec=-1, interrupted=0x7fffffffd8bc) at os_unix.c:5500 #5 0x000055555569de67 in mch_inchar (buf=buf@entry=0x555555a064f9 <typebuf_init+57> "", maxlen=69, wtime=wtime@entry=-1, tb_change_cnt=4) at os_unix.c:481 #6 0x000055555571f40e in ui_inchar (buf=buf@entry=0x555555a064f9 <typebuf_init+57> "", maxlen=maxlen@entry=69, wtime=wtime@entry=-1, tb_change_cnt=tb_change_cnt@entry=4) at ui.c:195 #7 0x00005555556387ea in inchar (buf=0x555555a064f9 <typebuf_init+57> "", maxlen=207, wait_time=-1, tb_change_cnt=4) at getchar.c:3065 #8 0x000055555563a0ed in vgetorpeek (advance=advance@entry=1) at getchar.c:2841 #9 0x000055555563b270 in vgetorpeek (advance=1) at getchar.c:1987 #10 vgetc () at getchar.c:1608 #11 0x000055555563b6f9 in safe_vgetc () at getchar.c:1804 #12 0x00005555556812c7 in normal_cmd (oap=0x7fffffffdc00, toplevel=1) at normal.c:628 #13 0x000055555576c875 in main_loop (cmdwin=0, noexmode=0) at main.c:1355 #14 0x000055555576d791 in vim_main2 () at main.c:908 #15 0x00005555555a9491 in main (argc=<optimized out>, argv=<optimized out>) at main.c:419 Full disclosure: My build includes a few extra patches from the Fedora RPM, but since Christian got a similar backtrace, I don't think those patches are related. Thanks, Aron -- -- 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 vim_dev+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.