diff options
| author | Hennadii Stepanov <[email protected]> | 2019-10-18 09:12:15 +0300 |
|---|---|---|
| committer | GitHub <[email protected]> | 2019-10-18 09:12:15 +0300 |
| commit | b5f0be38790ecc87a1e537edeca5923f608bc68c (patch) | |
| tree | 5ccc224b207f09bce5559a23542b2bf561630b93 /src | |
| parent | Merge #17162: chain: Remove CBlockIndex::SetNull helper (diff) | |
| download | discoin-b5f0be38790ecc87a1e537edeca5923f608bc68c.tar.xz discoin-b5f0be38790ecc87a1e537edeca5923f608bc68c.zip | |
util: Filter out macOS process serial number
Diffstat (limited to 'src')
| -rw-r--r-- | src/util/system.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/util/system.cpp b/src/util/system.cpp index 6199e5daa..526bf559c 100644 --- a/src/util/system.cpp +++ b/src/util/system.cpp @@ -379,6 +379,15 @@ bool ArgsManager::ParseParameters(int argc, const char* const argv[], std::strin for (int i = 1; i < argc; i++) { std::string key(argv[i]); + +#ifdef MAC_OSX + // At the first time when a user gets the "App downloaded from the + // internet" warning, and clicks the Open button, macOS passes + // a unique process serial number (PSN) as -psn_... command-line + // argument, which we filter out. + if (key.substr(0, 5) == "-psn_") continue; +#endif + if (key == "-") break; //bitcoin-tx using stdin std::string val; size_t is_index = key.find('='); |