Crypt the text in the undo file if the file itself is crypted.
diff --git a/runtime/doc/editing.txt b/runtime/doc/editing.txt
index 11f5748..32848ac 100644
--- a/runtime/doc/editing.txt
+++ b/runtime/doc/editing.txt
@@ -1366,6 +1366,9 @@
automatically to the method used when that file was written. You can change
'cryptmethod' before writing that file to change the method.
+When writing an undo file, the same key and method will be used for the text
+in the undo file. |persistent-undo|.
+
*E817* *E818* *E819* *E820*
When encryption does not work properly, you would be able to write your text
to a file and never be able to read it back. Therefore a test is performed to
diff --git a/runtime/doc/todo.txt b/runtime/doc/todo.txt
index 7210961..0bd8d67 100644
--- a/runtime/doc/todo.txt
+++ b/runtime/doc/todo.txt
@@ -1085,9 +1085,6 @@
- using NSIS 2.46: install on Windows 7 works, but no "Edit with Vim" menu.
Use register_shell_extension()? (George Reilly, 2010 May 26)
Ron's version: http://dev.ronware.org/p/vim/finfo?name=gvim.nsi
-- Persistent undo bugs / fixes:
- - Need to check all values for evil manipulation.
-- Also crypt the undo file.
- Also crypt the swap file, each block separately. Change mf_write() and
mf_read(). How to get b_p_key to these functions?
- Do profiling on sha256 code to find obvious bottlenecks.
diff --git a/runtime/doc/undo.txt b/runtime/doc/undo.txt
index 96ff96a..e8fed4f 100644
--- a/runtime/doc/undo.txt
+++ b/runtime/doc/undo.txt
@@ -225,6 +225,9 @@
Undo files are normally saved in the same directory as the file. This can be
changed with the 'undodir' option.
+When the file is encrypted, the text in the undo file is also crypted. The
+same key and method is used. |encryption|
+
You can also save and restore undo histories by using ":wundo" and ":rundo"
respectively:
*:wundo* *:rundo*