On Wed, Mar 23, 2016 at 5:36 AM, h_east <
h.eas...@gmail.com> wrote:
>
>> > On Mon, Mar 21, 2016 at 2:45 AM, Dominique Pellé
>> > <
dominiq...@gmail.com> wrote:
>> > > Hi
>> > >
>> > > afl-fuzz found another crash with use of freed memory in vim-7.4.1627
>> > > (and older) in quickfix code. This is a different bug that the one fixed
>> > > recently in Vim-7.4.1592:
>> > >
>> >
>> > The attached patch fixes this issue. These issues are caused by autocmds
>> > modifying the location list while the location list is being used.
>>
>> This issue also occurs with the quickfix.
>>
>> ]$ vim -Nu NONE -S crash_qf.vim
>> Vim: Caught deadly signal SEGV
>>
>> Vim: Finished.
>> Segmentation fault (core dumped)
>>
>> PS
>> I think we should abort even if `qi->qf_curlist` has changed.
>>
>> I'm sorry. In fact, I have had already written a patch.
>> But did not yet been submitted.
>> I'll send patch later.
>
> A patch is attached.
> Please check it.
>
The patch looks good to me. One comment: When the quickfix/location
the window is still valid/open. I think, in this case the new window needs
to be closed. The opened_window variable should be set to FALSE