Go to file
James McCoy 2dfb82f13e
Handle rename() failures
Renaming the temporary, encrypted file to the intended filename (per the
buffer) may fail (e.g., typoed directory name).  In this case, remove
the temporary file and then give the typical error message for this
situation.

In order to be safe, the message is manually being generated instead of
trying to be clever and do something like “noautocmd write” expecting it
to hit the same error that rename() did.

Closes jamessan/vim-gnupg#56
Signed-off-by: James McCoy <vega.james@gmail.com>
2015-12-17 21:52:12 -05:00
plugin Handle rename() failures 2015-12-17 21:52:12 -05:00