From 890ea05ac24746051d092518d0796e106b1715e3 Mon Sep 17 00:00:00 2001 From: Frantisek Sumsal Date: Mon, 14 Sep 2020 16:16:59 +0200 Subject: [PATCH] home: return SYNTHETIC_ERRNO() when appropriate --- src/home/homectl-fido2.c | 3 ++- src/home/homectl-pkcs11.c | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/home/homectl-fido2.c b/src/home/homectl-fido2.c index b7b2c1a3b5..0d087c79f0 100644 --- a/src/home/homectl-fido2.c +++ b/src/home/homectl-fido2.c @@ -534,6 +534,7 @@ finish: fido_dev_info_free(&di, di_size); return r; #else - return log_error_errno(EOPNOTSUPP, "FIDO2 tokens not supported on this build."); + return log_error_errno(SYNTHETIC_ERRNO(EOPNOTSUPP), + "FIDO2 tokens not supported on this build."); #endif } diff --git a/src/home/homectl-pkcs11.c b/src/home/homectl-pkcs11.c index f4253ed7bf..3507841faa 100644 --- a/src/home/homectl-pkcs11.c +++ b/src/home/homectl-pkcs11.c @@ -475,6 +475,7 @@ int find_pkcs11_token_auto(char **ret) { return 0; #else - return log_error_errno(EOPNOTSUPP, "PKCS#11 tokens not supported on this build."); + return log_error_errno(SYNTHETIC_ERRNO(EOPNOTSUPP), + "PKCS#11 tokens not supported on this build."); #endif } -- 2.25.1