On So, 09 Jul 2017, Dominique Pellé wrote: > 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? > > I could not reproduce it either so far using vim-8.0.704. But I see that > the script sent by the bug reporter contains things like > let l:background_file = expand('~/.vim/background') > and I don't have such a file ~/.vim/background. So it looks > like there are missing instructions to be able to reproduce the > crash.
Yeah, I created those files (put a colorscheme into ~/.vim/themes and a background setting into ~/.vim/background, be sure, to have something different than your usual settings and preferably, use a colorscheme that does not exist) and I now see this segfault: (gdb) bt #0 __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:51 #1 0x00007ffff426a3fa in __GI_abort () at abort.c:89 #2 0x00007ffff42a6bd0 in __libc_message (do_abort=do_abort@entry=2, fmt=fmt@entry=0x7ffff439bdd0 "*** Error in `%s': %s: 0x%s ***\n") at ../sysdeps/posix/libc_fatal.c:175 #3 0x00007ffff42acf96 in malloc_printerr (action=3, str=0x7ffff439bf28 "double free or corruption (fasttop)", ptr=<optimized out>, ar_ptr=<optimized out>) at malloc.c:5049 #4 0x00007ffff42ad7de in _int_free (av=0x7ffff45cfb00 <main_arena>, p=0x555555a920e0, have_lock=0) at malloc.c:3905 #5 0x000055555566eeb5 in vim_free (x=0x555555a920f0) at misc2.c:1793 #6 0x0000555555608700 in discard_exception (excp=0x555555ad6ed0, was_finished=0) at ex_eval.c:630 #7 0x0000555555608756 in discard_current_exception () at ex_eval.c:643 #8 0x00005555555ec4f3 in check_due_timer () at ex_cmds2.c:1239 #9 0x00005555556b61c7 in WaitForChar (msec=4000, interrupted=0x7fffffffdc90) at os_unix.c:5500 #10 0x00005555556b1125 in mch_inchar (buf=0x555555a65b14 <typebuf_init+84> "", maxlen=60, wtime=-1, tb_change_cnt=121) at os_unix.c:481 #11 0x0000555555750220 in ui_inchar (buf=0x555555a65b14 <typebuf_init+84> "", maxlen=60, wtime=-1, tb_change_cnt=121) at ui.c:195 #12 0x0000555555635b04 in inchar (buf=0x555555a65b14 <typebuf_init+84> "", maxlen=180, wait_time=-1, tb_change_cnt=121) at getchar.c:3065 #13 0x0000555555635730 in vgetorpeek (advance=1) at getchar.c:2841 #14 0x00005555556338ae in vgetc () at getchar.c:1608 #15 0x0000555555633de3 in safe_vgetc () at getchar.c:1804 #16 0x000055555567ff15 in normal_cmd (oap=0x7fffffffe060, toplevel=1) at normal.c:628 #17 0x00005555557c482c in main_loop (cmdwin=0, noexmode=0) at main.c:1355 #18 0x00005555557c3f96 in vim_main2 () at main.c:908 #19 0x00005555557c3627 in main (argc=5, argv=0x7fffffffe258) at main.c:419 Best, Christian -- Wie man sein Kind nicht nennen sollte: Zita Delle -- -- 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.