aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorsaturneric <[email protected]>2024-11-30 22:04:37 +0000
committersaturneric <[email protected]>2024-11-30 22:09:57 +0000
commit8f8337839e18f6c2141e0a8d944712cd2e41ba71 (patch)
tree9fd5fac316c3e05ccfbbc0d4d3ba7548339d8161
parentfix: debug lib and runtime output dir should be same as release (diff)
downloadGpgFrontend-8f8337839e18f6c2141e0a8d944712cd2e41ba71.tar.gz
GpgFrontend-8f8337839e18f6c2141e0a8d944712cd2e41ba71.zip
fix: solve build issue on windows
-rw-r--r--src/core/GpgCoreInit.cpp3
-rw-r--r--src/core/function/GlobalSettingStation.cpp2
2 files changed, 3 insertions, 2 deletions
diff --git a/src/core/GpgCoreInit.cpp b/src/core/GpgCoreInit.cpp
index bcb57036..34ac866b 100644
--- a/src/core/GpgCoreInit.cpp
+++ b/src/core/GpgCoreInit.cpp
@@ -127,7 +127,8 @@ auto InitGpgME() -> bool {
#if defined(_WIN32) || defined(WIN32)
auto w32spawn_dir =
GlobalSettingStation::GetInstance().GetAppDir() + "/../gnupg/bin";
- if (gpgme_set_global_flag("w32-inst-dir", w32spawn_dir) != 0) {
+ if (gpgme_set_global_flag("w32-inst-dir",
+ w32spawn_dir.toUtf8().constData()) != 0) {
LOG_E() << "gpgme_set_global_flag() with argument 'w32spawn_dir' failed, "
"abort...";
return false;
diff --git a/src/core/function/GlobalSettingStation.cpp b/src/core/function/GlobalSettingStation.cpp
index c0b935f5..367437da 100644
--- a/src/core/function/GlobalSettingStation.cpp
+++ b/src/core/function/GlobalSettingStation.cpp
@@ -72,7 +72,7 @@ class GlobalSettingStation::Impl {
[[nodiscard]] auto GetSettings() -> QSettings {
#if defined(_WIN32) || defined(WIN32)
- return QSettings(app_config_file_path_, QSettings::IniFormat);
+ return QSettings(app_config_file_path(), QSettings::IniFormat);
#else
return QSettings();
#endif