diff options
| author | Miguel Herranz <miguel@ipglider.org> | 2018-01-31 00:08:27 +0100 |
|---|---|---|
| committer | Miguel Herranz <miguel@ipglider.org> | 2018-01-31 00:08:27 +0100 |
| commit | 08beb71cca368537b8d215429500baa4427c4039 (patch) | |
| tree | 419631bccda7ecad9fc364ad746aea483a36de4e /src | |
| parent | 3b069ec04908f76b8244a96124ce9619c0b0300d (diff) | |
| download | monzero-gui-08beb71cca368537b8d215429500baa4427c4039.tar.gz monzero-gui-08beb71cca368537b8d215429500baa4427c4039.tar.xz monzero-gui-08beb71cca368537b8d215429500baa4427c4039.zip | |
Store wallet log in ~/Library/Logs/ in macOS
In macOS it is not usual to modify anything inside an application. If
the user that runs the application doesn't have writing permissions the
log will not be saved.
This modifies the path to store them in macOS' standard location for
application logs.
Diffstat (limited to 'src')
| -rw-r--r-- | src/libwalletqt/Wallet.cpp | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/libwalletqt/Wallet.cpp b/src/libwalletqt/Wallet.cpp index b694a05f..a87e9a20 100644 --- a/src/libwalletqt/Wallet.cpp +++ b/src/libwalletqt/Wallet.cpp @@ -658,7 +658,13 @@ QString Wallet::getDaemonLogPath() const QString Wallet::getWalletLogPath() const { - return QCoreApplication::applicationDirPath() + "/monero-wallet-gui.log"; + const QString filename("monero-wallet-gui.log"); + +#ifdef Q_OS_MACOS + return QStandardPaths::standardLocations(QStandardPaths::HomeLocation).at(0) + "/Library/Logs/" + filename; +#else + return QCoreApplication::applicationDirPath() + "/" + filename; +#endif } Wallet::Wallet(Monero::Wallet *w, QObject *parent) |
