patch 7.4.1137
Problem: Illegal memory access when using :copen and :cclose.
Solution: Avoid that curbuf is invalid. (suggestion by Justin M. Keyes)
Add a test.
diff --git a/src/testdir/test_quickfix.vim b/src/testdir/test_quickfix.vim
index b2fc968..a4d0f20 100644
--- a/src/testdir/test_quickfix.vim
+++ b/src/testdir/test_quickfix.vim
@@ -295,4 +295,10 @@
endfunc
+function Test_helpgrep()
+ helpgrep quickfix
+ copen
+ " This wipes out the buffer, make sure that doesn't cause trouble.
+ cclose
+endfunc