Skip to content

Commit c4bfeda

Browse files
committed
patch 8.0.0134
Problem: Null pointer access reported by UBsan. Solution: Check curwin->w_buffer is not NULL. (Yegappan Lakshmanan)
1 parent fe38b49 commit c4bfeda

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

src/ex_cmds.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3967,7 +3967,8 @@ do_ecmd(
39673967
* <VN> We could instead free the synblock
39683968
* and re-attach to buffer, perhaps.
39693969
*/
3970-
if (curwin->w_s == &(curwin->w_buffer->b_s))
3970+
if (curwin->w_buffer != NULL
3971+
&& curwin->w_s == &(curwin->w_buffer->b_s))
39713972
curwin->w_s = &(buf->b_s);
39723973
#endif
39733974
curwin->w_buffer = buf;

src/version.c

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

765765
static int included_patches[] =
766766
{ /* Add new patch number below this line */
767+
/**/
768+
134,
767769
/**/
768770
133,
769771
/**/

0 commit comments

Comments
 (0)