Patch 8.2.4851
Problem: Compiler warning for uninitialized variable.
Solution: Use another variable to decide to restore option values.
Files: src/session.c
*** ../vim-8.2.4850/src/session.c 2022-04-30 16:10:23.970106114 +0100
--- src/session.c 2022-05-01 00:32:26.487946216 +0100
***************
*** 620,625 ****
--- 620,626 ----
int only_save_windows = TRUE;
int nr;
int restore_size = TRUE;
+ int restore_height_width = FALSE;
win_T *wp;
char_u *sname;
win_T *edited_win = NULL;
***************
*** 887,892 ****
--- 888,894 ----
|| put_line(fd, "set winminwidth=0") == FAIL
|| put_line(fd, "set winwidth=1") == FAIL)
goto fail;
+ restore_height_width = TRUE;
}
if (nr > 1 && ses_winsizes(fd, restore_size, tab_firstwin) == FAIL)
goto fail;
***************
*** 979,985 ****
goto fail;
}
! if (tab_firstwin->w_next != NULL)
{
// Restore 'winminheight' and 'winminwidth'.
if (put_line(fd, "let &winminheight = s:save_winminheight") == FAIL
--- 981,987 ----
goto fail;
}
! if (restore_height_width)
{
// Restore 'winminheight' and 'winminwidth'.
if (put_line(fd, "let &winminheight = s:save_winminheight") == FAIL
*** ../vim-8.2.4850/src/version.c 2022-04-30 16:10:23.970106114 +0100
--- src/version.c 2022-05-01 00:40:14.287043626 +0100
***************
*** 748,749 ****
--- 748,751 ----
{ /* Add new patch number below this line */
+ /**/
+ 4851,
/**/
--
>From "know your smileys":
(:-# Said something he shouldn't have
/// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net \\\
/// \\\
\\\ sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ ///
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
--
--
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
---
You received this message because you are subscribed to the Google Groups
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/vim_dev/20220430234514.DB5041C19BB%40moolenaar.net.