diff options
author | Andy Savage <andy.savage@noisyduck.co.uk> | 2020-12-15 17:00:39 +0000 |
---|---|---|
committer | Andy Savage <andy.savage@noisyduck.co.uk> | 2020-12-15 17:00:39 +0000 |
commit | c65f097ebd6be6743f4fa8fd27d4d82bbd28d005 (patch) | |
tree | 26b95930d5b34141d074a7680ab4ead0ad628337 /core/io/file_access_encrypted.cpp | |
parent | 6ccc6b6e28a49a40d6e31e66fc1ef258141c3f1d (diff) |
Quick fix to incorrect error messages when writing to compressed or encrypted files.
Diffstat (limited to 'core/io/file_access_encrypted.cpp')
-rw-r--r-- | core/io/file_access_encrypted.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/core/io/file_access_encrypted.cpp b/core/io/file_access_encrypted.cpp index 2ac24d5169..cf5800b472 100644 --- a/core/io/file_access_encrypted.cpp +++ b/core/io/file_access_encrypted.cpp @@ -256,7 +256,7 @@ Error FileAccessEncrypted::get_error() const { } void FileAccessEncrypted::store_buffer(const uint8_t *p_src, int p_length) { - ERR_FAIL_COND_MSG(!writing, "File has not been opened in read mode."); + ERR_FAIL_COND_MSG(!writing, "File has not been opened in write mode."); if (pos < data.size()) { for (int i = 0; i < p_length; i++) { @@ -272,13 +272,13 @@ void FileAccessEncrypted::store_buffer(const uint8_t *p_src, int p_length) { } void FileAccessEncrypted::flush() { - ERR_FAIL_COND_MSG(!writing, "File has not been opened in read mode."); + ERR_FAIL_COND_MSG(!writing, "File has not been opened in write mode."); // encrypted files keep data in memory till close() } void FileAccessEncrypted::store_8(uint8_t p_dest) { - ERR_FAIL_COND_MSG(!writing, "File has not been opened in read mode."); + ERR_FAIL_COND_MSG(!writing, "File has not been opened in write mode."); if (pos < data.size()) { data.write[pos] = p_dest; |