diff options
author | Wladimir J. van der Laan <laanwj@gmail.com> | 2012-10-04 07:47:10 +0200 |
---|---|---|
committer | Wladimir J. van der Laan <laanwj@gmail.com> | 2012-10-04 12:04:12 +0200 |
commit | 61fd72695f291a7a083cdc8ba96bda971c19eb53 (patch) | |
tree | e8069300e8b6aaef7a8af70720e658016fece841 | |
parent | 0547b02af78dcf2d84e4905b56c7f95d9582b2f9 (diff) |
When datadir missing, show messagebox instead of printing error to stderr
-rw-r--r-- | src/qt/bitcoin.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/qt/bitcoin.cpp b/src/qt/bitcoin.cpp index ad145fdf9d..cd1764a53f 100644 --- a/src/qt/bitcoin.cpp +++ b/src/qt/bitcoin.cpp @@ -132,7 +132,10 @@ int main(int argc, char *argv[]) // ... then bitcoin.conf: if (!boost::filesystem::is_directory(GetDataDir(false))) { - fprintf(stderr, "Error: Specified directory does not exist\n"); + // This message can not be translated, as translation is not initialized yet + // (which not yet possible because lang=XX can be overridden in bitcoin.conf in the data directory) + QMessageBox::critical(0, "Bitcoin", + QString("Error: Specified data directory \"%1\" does not exist.").arg(QString::fromStdString(mapArgs["-datadir"]))); return 1; } ReadConfigFile(mapArgs, mapMultiArgs); |