diff options
author | Bram Moolenaar <Bram@vim.org> | 2023-05-27 18:02:55 +0100 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2023-05-27 18:02:55 +0100 |
commit | 3a2a60ce4a8e73594bca16814672fcc243d093ac (patch) | |
tree | 4a105c50b7f3a3e219e49bd73f5f4730d90bcefd /src/structs.h | |
parent | a40c0bcc83c32da02869f59b10538d6327df61c5 (diff) |
patch 9.0.1583: get E304 when using 'cryptmethod' "xchacha20v2"v9.0.1583
Problem: Get E304 when using 'cryptmethod' "xchacha20v2". (Steve Mynott)
Solution: Add 4th crypt method to block zero ID check. Avoid syncing a swap
file before reading the file. (closes #12433)
Diffstat (limited to 'src/structs.h')
-rw-r--r-- | src/structs.h | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/structs.h b/src/structs.h index 03fb92e40d..5df8f841a0 100644 --- a/src/structs.h +++ b/src/structs.h @@ -691,6 +691,12 @@ typedef struct int cmod_did_esilent; // incremented when emsg_silent is } cmdmod_T; +typedef enum { + MF_DIRTY_NO = 0, // no dirty blocks + MF_DIRTY_YES, // there are dirty blocks + MF_DIRTY_YES_NOSYNC, // there are dirty blocks, do not sync yet +} mfdirty_T; + #define MF_SEED_LEN 8 struct memfile @@ -712,7 +718,7 @@ struct memfile blocknr_T mf_neg_count; // number of negative blocks numbers blocknr_T mf_infile_count; // number of pages in the file unsigned mf_page_size; // number of bytes in a page - int mf_dirty; // TRUE if there are dirty blocks + mfdirty_T mf_dirty; #ifdef FEAT_CRYPT buf_T *mf_buffer; // buffer this memfile is for char_u mf_seed[MF_SEED_LEN]; // seed for encryption |