Patch 8.2.2016
Problem:    Swap file test is a little flaky.
Solution:   Don't set a byte to a fixed value, increment it.
Files:      src/testdir/test_swap.vim


*** ../vim-8.2.2015/src/testdir/test_swap.vim   2020-11-09 21:04:12.203986366 
+0100
--- src/testdir/test_swap.vim   2020-11-19 18:56:50.315763866 +0100
***************
*** 417,423 ****
    " swap file should be automatically deleted.
    bwipe!
    " change the process ID to avoid the "still running" warning
!   let swapfile_bytes[24] = 0x99
    call writefile(swapfile_bytes, swapfile_name)
    edit Xtest.scr
    " will end up using the same swap file after deleting the existing one
--- 417,423 ----
    " swap file should be automatically deleted.
    bwipe!
    " change the process ID to avoid the "still running" warning
!   let swapfile_bytes[24] = swapfile_bytes[24] + 1
    call writefile(swapfile_bytes, swapfile_name)
    edit Xtest.scr
    " will end up using the same swap file after deleting the existing one
***************
*** 433,439 ****
    augroup END
  
    " change the host name
!   let swapfile_bytes[28 + 40] = 0x89
    call writefile(swapfile_bytes, swapfile_name)
    edit Xtest.scr
    call assert_equal(1, filereadable(swapfile_name))
--- 433,439 ----
    augroup END
  
    " change the host name
!   let swapfile_bytes[28 + 40] = swapfile_bytes[28 + 40] + 2
    call writefile(swapfile_bytes, swapfile_name)
    edit Xtest.scr
    call assert_equal(1, filereadable(swapfile_name))
*** ../vim-8.2.2015/src/version.c       2020-11-19 18:53:15.188492574 +0100
--- src/version.c       2020-11-19 18:54:38.836227052 +0100
***************
*** 752,753 ****
--- 752,755 ----
  {   /* Add new patch number below this line */
+ /**/
+     2016,
  /**/

-- 
press CTRL-ALT-DEL for more information

 /// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net   \\\
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\  an exciting new programming language -- http://www.Zimbu.org        ///
 \\\            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/202011191758.0AJHwYQ0414077%40masaka.moolenaar.net.

Raspunde prin e-mail lui