From 2aa49ce9fe618bda9bf70fd57b23fe4802f0aeff Mon Sep 17 00:00:00 2001 From: Luke Dashjr Date: Tue, 17 Nov 2015 20:29:42 +0000 Subject: [PATCH] Bugfix: Use unique autostart filenames on Linux for testnet/regtest --- src/qt/guiutil.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/qt/guiutil.cpp b/src/qt/guiutil.cpp index 23e657677..9600a54c4 100644 --- a/src/qt/guiutil.cpp +++ b/src/qt/guiutil.cpp @@ -354,7 +354,10 @@ boost::filesystem::path static GetAutostartDir() boost::filesystem::path static GetAutostartFilePath() { - return GetAutostartDir() / "bitcoin.desktop"; + std::string chain = ChainNameFromCommandLine(); + if (chain == CBaseChainParams::MAIN) + return GetAutostartDir() / "bitcoin.desktop"; + return GetAutostartDir() / strprintf("bitcoin-%s.lnk", chain); } bool GetStartOnSystemStartup()