Mercurial > vim
comparison src/window.c @ 19291:1d6bc6b31c2e v8.2.0204
patch 8.2.0204: crash when using winnr('j') in a popup window
Commit: https://github.com/vim/vim/commit/631ebc48149a0446dd9ffbddd3e2822252085885
Author: Bram Moolenaar <Bram@vim.org>
Date: Mon Feb 3 22:15:26 2020 +0100
patch 8.2.0204: crash when using winnr('j') in a popup window
Problem: Crash when using winnr('j') in a popup window.
Solution: Do not search for neighbors in a popup window. (closes https://github.com/vim/vim/issues/5568)
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Mon, 03 Feb 2020 22:30:03 +0100 |
parents | 2142fb624658 |
children | 435726a03481 |
comparison
equal
deleted
inserted
replaced
19290:144353345c9b | 19291:1d6bc6b31c2e |
---|---|
4429 { | 4429 { |
4430 frame_T *fr; | 4430 frame_T *fr; |
4431 frame_T *nfr; | 4431 frame_T *nfr; |
4432 frame_T *foundfr; | 4432 frame_T *foundfr; |
4433 | 4433 |
4434 #ifdef FEAT_PROP_POPUP | |
4435 if (popup_is_popup(wp)) | |
4436 // popups don't have neighbors. | |
4437 return NULL; | |
4438 #endif | |
4434 foundfr = wp->w_frame; | 4439 foundfr = wp->w_frame; |
4435 while (count--) | 4440 while (count--) |
4436 { | 4441 { |
4437 /* | 4442 /* |
4438 * First go upwards in the tree of frames until we find a upwards or | 4443 * First go upwards in the tree of frames until we find a upwards or |
4511 { | 4516 { |
4512 frame_T *fr; | 4517 frame_T *fr; |
4513 frame_T *nfr; | 4518 frame_T *nfr; |
4514 frame_T *foundfr; | 4519 frame_T *foundfr; |
4515 | 4520 |
4521 #ifdef FEAT_PROP_POPUP | |
4522 if (popup_is_popup(wp)) | |
4523 // popups don't have neighbors. | |
4524 return NULL; | |
4525 #endif | |
4516 foundfr = wp->w_frame; | 4526 foundfr = wp->w_frame; |
4517 while (count--) | 4527 while (count--) |
4518 { | 4528 { |
4519 /* | 4529 /* |
4520 * First go upwards in the tree of frames until we find a left or | 4530 * First go upwards in the tree of frames until we find a left or |