summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorWerner Koch <wk@gnupg.org>2023-06-09 13:46:11 +0200
committerWerner Koch <wk@gnupg.org>2023-06-09 16:29:04 +0200
commitca3f0e66bcf669181ec0bf50c83130eee2648acc (patch)
treeba7d892f5db5415682a217554fd97f753f48afef
parentgpg: Add --list-filter properties key_expires and key_expires_d. (diff)
downloadgnupg2-ca3f0e66bcf669181ec0bf50c83130eee2648acc.tar.xz
gnupg2-ca3f0e66bcf669181ec0bf50c83130eee2648acc.zip
w32: Map ERROR_FILE_INVALID to EIO.
* common/sysutils.c (map_w32_to_errno): Add mapping. -- We see this error sometimes when writing to an USB connected disk.
-rw-r--r--common/sysutils.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/common/sysutils.c b/common/sysutils.c
index 01510ddb0..231565177 100644
--- a/common/sysutils.c
+++ b/common/sysutils.c
@@ -252,6 +252,9 @@ map_w32_to_errno (DWORD w32_err)
case ERROR_ALREADY_EXISTS:
return EEXIST;
+ case ERROR_FILE_INVALID:
+ return EIO;
+
/* This mapping has been taken from reactOS. */
case ERROR_TOO_MANY_OPEN_FILES: return EMFILE;
case ERROR_ARENA_TRASHED: return ENOMEM;