On Wed, December 5, 2012 15:17, Bram Moolenaar wrote: > Patch 7.3.746 […] > + /* Somehow qf_count may have an incorrect value, set it to 1 > + * to avoid crashing when it's wrong. > + * TODO: Avoid qf_count being incorrect. */ > + qi->qf_lists[idx].qf_count = 1;
I finally found the root cause of having qf_count being wrong. The vimgrep doesn't expect, that the quickfix list changes between loading files and uses qf_add_entry() to add entries, which happily increments qf_count of the wrong curlist, while the actual entries will always be attached at the correct position to which prevp points to. I think, this patch prevents it, by checking that qi->curlist is always the one, vimgrep expects. But please check. I am not entirely sure this works correctly in all situations, but at least my tests have all been successful so far (valgrind did not report errors, the test suite runs as expected and the crashes are avoided) regards, Christian -- 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
vimgrep_autocmd_corruptions.diff
Description: Binary data
