Skip to content

Commit b27bd6d

Browse files
committed
updated for version 7.3.1292
Problem: Possibly using invalid pointer when searcing for window. (Raichoo) Solution: Use "firstwin" instead of "tp_firstwin" for current tab.
1 parent 0dd29a1 commit b27bd6d

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

src/version.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -728,6 +728,8 @@ static char *(features[]) =
728728

729729
static int included_patches[] =
730730
{ /* Add new patch number below this line */
731+
/**/
732+
1292,
731733
/**/
732734
1291,
733735
/**/

src/window.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4077,7 +4077,8 @@ win_find_tabpage(win)
40774077
tabpage_T *tp;
40784078

40794079
for (tp = first_tabpage; tp != NULL; tp = tp->tp_next)
4080-
for (wp = tp->tp_firstwin; wp != NULL; wp = wp->w_next)
4080+
for (wp = (tp == curtab ? firstwin : tp->tp_firstwin);
4081+
wp != NULL; wp = wp->w_next)
40814082
if (wp == win)
40824083
return tp;
40834084
return NULL;

0 commit comments

Comments
 (0)