To: vim-dev@vim.org Subject: Patch 5.7.001 Fcc: outbox From: Bram Moolenaar ------------ Patch 5.7.001 Problem: When the current buffer is crypted, and another modified buffer isn't, ":wall" will encrypt the other buffer. Solution: In buf_write() use "buf" instead of "curbuf" to check for the crypt key. Files: src/fileio.c *** ../vim-5.7/src/fileio.c Sat Jun 24 13:54:27 2000 --- src/fileio.c Sun Jun 25 20:14:38 2000 *************** *** 1857,1865 **** start = end + 1; #ifdef CRYPTV ! if (*curbuf->b_p_key) { ! crypt_init_keys(curbuf->b_p_key); encrypted = TRUE; /* Write magic number, so that Vim knows that this file is encrypted * when reading it again */ --- 1857,1865 ---- start = end + 1; #ifdef CRYPTV ! if (*buf->b_p_key) { ! crypt_init_keys(buf->b_p_key); encrypted = TRUE; /* Write magic number, so that Vim knows that this file is encrypted * when reading it again */ *** ../vim-5.7/src/version.c Sat Jun 24 13:54:21 2000 --- src/version.c Sun Jun 25 20:14:50 2000 *************** *** 439,440 **** --- 439,442 ---- { /* Add new patch number below this line */ + /**/ + 1, /**/ -- In a world without walls and borders, who needs windows and gates? /-/-- Bram Moolenaar --- Bram@moolenaar.net --- http://www.moolenaar.net --\-\ \-\-- Vim: http://www.vim.org ---- ICCF Holland: http://www.vim.org/iccf --/-/