aboutsummaryrefslogtreecommitdiffstats
path: root/src/core/utils/GpgUtils.cpp
diff options
context:
space:
mode:
authorsaturneric <[email protected]>2024-07-30 18:42:12 +0000
committersaturneric <[email protected]>2024-07-30 18:42:12 +0000
commitdbb4a21931cd10a3caed3c446af0fe06de9873b1 (patch)
treeb3eb2e6fc3e67ea274472dfacfa3451848b43c80 /src/core/utils/GpgUtils.cpp
parentfix: solve known issues on build (diff)
downloadGpgFrontend-dbb4a21931cd10a3caed3c446af0fe06de9873b1.tar.gz
GpgFrontend-dbb4a21931cd10a3caed3c446af0fe06de9873b1.zip
feat: simplify logging
Diffstat (limited to 'src/core/utils/GpgUtils.cpp')
-rw-r--r--src/core/utils/GpgUtils.cpp28
1 files changed, 14 insertions, 14 deletions
diff --git a/src/core/utils/GpgUtils.cpp b/src/core/utils/GpgUtils.cpp
index 28892063..3d584b8f 100644
--- a/src/core/utils/GpgUtils.cpp
+++ b/src/core/utils/GpgUtils.cpp
@@ -50,9 +50,9 @@ auto GetGpgmeErrorString(gpgme_error_t err) -> QString {
auto CheckGpgError(GpgError err) -> GpgError {
auto err_code = gpg_err_code(err);
if (err_code != GPG_ERR_NO_ERROR) {
- qCWarning(core) << "gpg operation failed [error code: " << err_code
- << "], source: " << gpgme_strsource(err)
- << " description: " << GetGpgmeErrorString(err);
+ LOG_W() << "gpg operation failed [error code: " << err_code
+ << "], source: " << gpgme_strsource(err)
+ << " description: " << GetGpgmeErrorString(err);
}
return err_code;
}
@@ -61,15 +61,15 @@ auto CheckGpgError2ErrCode(GpgError err, GpgError predict) -> GpgErrorCode {
auto err_code = gpg_err_code(err);
if (err_code != gpg_err_code(predict)) {
if (err_code == GPG_ERR_NO_ERROR) {
- qCInfo(core) << "[Warning " << gpg_err_code(err)
- << "] Source: " << gpgme_strsource(err)
- << " description: " << GetGpgmeErrorString(err)
- << " predict: " << GetGpgmeErrorString(predict);
+ LOG_I() << "[Warning " << gpg_err_code(err)
+ << "] Source: " << gpgme_strsource(err)
+ << " description: " << GetGpgmeErrorString(err)
+ << " predict: " << GetGpgmeErrorString(predict);
} else {
- qCWarning(core) << "[Error " << gpg_err_code(err)
- << "] Source: " << gpgme_strsource(err)
- << " description: " << GetGpgmeErrorString(err)
- << " predict: " << GetGpgmeErrorString(predict);
+ LOG_W() << "[Error " << gpg_err_code(err)
+ << "] Source: " << gpgme_strsource(err)
+ << " description: " << GetGpgmeErrorString(err)
+ << " predict: " << GetGpgmeErrorString(predict);
}
}
return err_code;
@@ -81,9 +81,9 @@ auto DescribeGpgErrCode(GpgError err) -> GpgErrorDesc {
auto CheckGpgError(GpgError err, const QString& /*comment*/) -> GpgError {
if (gpg_err_code(err) != GPG_ERR_NO_ERROR) {
- qCWarning(core) << "[Error " << gpg_err_code(err)
- << "] Source: " << gpgme_strsource(err)
- << " description: " << GetGpgmeErrorString(err);
+ LOG_W() << "[Error " << gpg_err_code(err)
+ << "] Source: " << gpgme_strsource(err)
+ << " description: " << GetGpgmeErrorString(err);
}
return err;
}