> Following on from a bug report I made on the Syntastic issue list:
> https://github.com/scrooloose/syntastic/issues/151
> "When the error list window is open, along with the file it was opened
> with, you can cause a segfault to happen by just quitting the source
> file (while the error list is still open)
> This doesn't happen when a second file (either with, or without an
> error window) - only when it is the last file open."
>
> ... The developer there believes that this is a vim issue, and not a
> syntastic one, so I'm posting this here in the hope that something
> useful comes of it!
>
> mvim --version:
> VIM - Vi IMproved 7.3 (2010 Aug 15, compiled Jan 18 2012 09:35:39)
> MacOS X (unix) version
> Included patches: 1-390
> Compiled by dan...@Daniel-Hunts-MacBook-Pro.local
> Huge version with MacVim GUI. Features included (+) or not (-):
I can't reproduce it. If someone can, please use gdb to get a stack
trace.
--
Ed's Radiator Shop: The Best Place in Town to Take a Leak.
/// Bram Moolenaar -- Br...@Moolenaar.net -- http://www.Moolenaar.net \\\
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\ an exciting new programming language -- http://www.Zimbu.org ///
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
Please, do not top-post on this list. It makes it harder to make sense
of a quoted conversation. Thanks!
> On Mon, Feb 20, 2012 at 9:37 PM, Bram Moolenaar <Br...@moolenaar.net> wrote:
>> I can't reproduce it. If someone can, please use gdb to get a stack
>> trace.
The thing Daniel seems to have forgotten to mention is that this
requires an autocommand:
autocmd BufWinLeave * if empty(&bt) | lclose | endif
100% reproducible for me as well.
--
Pozdrawiam,
Lech Lorens
I don't know whether gdb comes installed by default on a Mac or if you
have to install it manually. Either way, make sure you have it, then:
1. Build Vim with debugging symbols (`make CFLAGS=-g`) and install
2. In the shell, type `gdb gvim`
3. At the "(gdb)" prompt, type `run`. Gvim should start.
4. Cause the error to occur. The gdb terminal should display a
message like "Program received SIGSEGV...".
5. Type `bt` at the "(gdb)" prompt to produce a backtrace
Sending in a backtrace just in case:
(gdb) bt
#0 0x0815b0a5 in update_screen (type=40) at screen.c:475
#1 0x081e739a in main_loop (cmdwin=0, noexmode=0) at main.c:1185
#2 0x081e6fcd in main (argc=3, argv=0xbffff0f4) at main.c:986
In this code snippet:
/*
* Correct stored syntax highlighting info for changes in each displayed
* buffer. Each buffer must only be done once.
*/
FOR_ALL_WINDOWS(wp)
{
if (wp->w_buffer->b_mod_set)
{
# ifdef FEAT_WINDOWS
win_T *wwp;
it it the line that checks whether wb->w_buffer->b_mod_set is non-zero:
if (wp->w_buffer->b_mod_set)
wp->w_buffer is NULL.
--
Pozdrawiam,
Lech Lorens
And just for good measure, my own one too:
Program received signal EXC_BAD_ACCESS, Could not access memory.
Reason: KERN_INVALID_ADDRESS at address: 0x00000000000000b8
0x000000010010fde3 in update_screen ()
(gdb) bt
#0 0x000000010010fde3 in update_screen ()
#1 0x000000010018fd40 in main_loop ()
#2 0x0000000100193c72 in main ()
(I haven't compiled vim with the debugging symbols, but it may not be
necessary now that we've confirmed it's in the same place across
systems?)
OK, I can reproduce it now. I was using a quickfix window, and "cclose"
has the same problem.
The stack trace at the time of the crash doesn't show what happens, it's
probably because the quickfix window is closed while closing the other
window.
--
How many light bulbs does it take to change a person?
Without wanting to be a pain - any progress on this?
Dan
It was fixed in patch 7.3.449.
http://ftp.vim.org/pub/vim/patches/7.3/7.3.449
--
James
GPG Key: 4096R/331BA3DB 2011-12-05 James McCoy <jame...@jamessan.com>
Ah I see - thank you!
Looks like I'll have to wait a while to see it filter through to brew on OSX.
Cheers again,
Dan
You can always compile it yourself straight from Mercurial. A lot of
people prefer to do that to stay more up-to-date with new patches.