summaryrefslogtreecommitdiff
path: root/src/popupwin.c
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2019-07-01 22:21:01 +0200
committerBram Moolenaar <Bram@vim.org>2019-07-01 22:21:01 +0200
commit7866b87958cf0c2f3312f2c3d7fb8d6eed28b512 (patch)
treeb952f2359356a2c434aa747d67f1362a7a2e6295 /src/popupwin.c
parentf8a071265535b8cc43e50a81f4d5049883ca50e4 (diff)
downloadvim-git-7866b87958cf0c2f3312f2c3d7fb8d6eed28b512.tar.gz
patch 8.1.1615: crash when passing buffer number to popup_create()v8.1.1615
Problem: Crash when passing buffer number to popup_create(). (Yasuhiro Matsumoto) Solution: Initialze the window properly.
Diffstat (limited to 'src/popupwin.c')
-rw-r--r--src/popupwin.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/popupwin.c b/src/popupwin.c
index 3af35b6f0..d988cbaf9 100644
--- a/src/popupwin.c
+++ b/src/popupwin.c
@@ -1056,8 +1056,7 @@ popup_create(typval_T *argvars, typval_T *rettv, create_type_T type)
{
// use existing buffer
new_buffer = FALSE;
- wp->w_buffer = buf;
- ++buf->b_nwindows;
+ win_init_popup_win(wp, buf);
buffer_ensure_loaded(buf);
}
else