aboutsummaryrefslogtreecommitdiff
path: root/src/util.h
AgeCommit message (Collapse)Author
2017-07-16Fix incorrect Doxygen tag (@ince → @since). Make Doxygen parameter names ↵practicalswift
match actual parameter names.
2017-06-25[RPC] Add an uptime command that displays the amount of time that bitcoind ↵Ricardo Velhote
has been running
2017-06-22Merge #10565: [coverage] Remove subtrees and benchmarks from coverage reportWladimir J. van der Laan
d5711f4 Filter subtrees and and benchmarks from coverage report (Andrew Chow) 405b86a Replace lcov -r commands with faster way (Andrew Chow) c8914b9 Have `make cov` optionally include branch coverage statistics (Andrew Chow) Tree-SHA512: 9c349a7baeb7430ea586617c52f91177df58e3546d6dc573e26815ddb79e30ab1873542d85ac1daca5e1fb2c6d6c8965824b42d027b6b0496a744af57b095852
2017-06-14[trivial] fix indentation for ArgsManager classJohn Newbery
2017-06-14Merge #9895: Turn TryCreateDirectory() into TryCreateDirectories()Wladimir J. van der Laan
1d1ea9f Turn TryCreateDirectory() into TryCreateDirectories() (Marko Bencun) Tree-SHA512: 49a524167bcf66e351a964c88d09cb3bcee12769a32da83410e3ba649fa4bcdbf0478d41e4d09bb55adb9b3f122e742271db6feb30bbafe2a7973542b5f10f79
2017-06-14Turn TryCreateDirectory() into TryCreateDirectories()Marko Bencun
Use case: TryCreateDirectory(GetDataDir() / "blocks" / "index") would fail if the blocks directory was not explicitly created before. The line that did so was in a weird location and could be removed as a result.
2017-06-09Remove unused Boost includespracticalswift
2017-06-07Have `make cov` optionally include branch coverage statisticsAndrew Chow
Added an option to configure to allow for branch coverage statistics gathering. Disabled logprint macro when coverage testing is on so that unnecessary branches are not analyzed.
2017-05-30[trivial] Fix comment for ForceSetArg()John Newbery
2017-05-09Util: Put mapMultiArgs inside ArgsManagerJorge Timón
- Set ArgsManager::mapMultiArgs in ArgsManager::SoftSetArg, ForceSetArg, SoftSetBoolArg
2017-05-09Util: Create ArgsManager class...Jorge Timón
- Introduce ArgsManager::GetArgs() - Adapt util_tests.cpp to ArgsManager
2017-04-10[rpc] Add logging RPCJohn Newbery
Adds an RPC to get and set currently active logging categories.
2017-04-03Replace uses of boost::filesystem with fsWladimir J. van der Laan
Step two in abstracting away boost::filesystem. To repeat this, simply run: ``` git ls-files \*.cpp \*.h | xargs sed -i 's/boost::filesystem/fs/g' ```
2017-04-03Replace includes of boost/filesystem.h with fs.hWladimir J. van der Laan
This is step one in abstracting the use of boost::filesystem.
2017-04-01Change LogAcceptCategory to use uint32_t rather than sets of strings.Gregory Maxwell
This changes the logging categories to boolean flags instead of strings. This simplifies the acceptance testing by avoiding accessing a scoped static thread local pointer to a thread local set of strings. It eliminates the only use of boost::thread_specific_ptr outside of lockorder debugging. This change allows log entries to be directed to multiple categories and makes it easy to change the logging flags at runtime (e.g. via an RPC, though that isn't done by this commit.) It also eliminates the fDebug global. Configuration of unknown logging categories now produces a warning.
2017-03-16util: rename variable to avoid shadowingPavol Rusnak
2017-03-13util: Throw tinyformat::format_error on formatting errorWladimir J. van der Laan
Throw tinyformat::format_error on formatting error instead of the `std::runtime_error`.
2017-03-12util: Properly handle errors during log message formattingWladimir J. van der Laan
Instead of having an exception propagate into the program when an error happens while formatting a log message, just print a message to the log. Addresses #9423.
2017-01-05Merge #9417: Do not evaluate hidden LogPrint argumentsWladimir J. van der Laan
407cdd6 Do not evaluate hidden LogPrint arguments (Pieter Wuille)
2016-12-31Increment MIT Licence copyright header year on files modified in 2016isle2983
Edited via: $ contrib/devtools/copyright_header.py update .
2016-12-27Add a ForceSetArg method for testingMatt Corallo
2016-12-24Un-expose mapArgs from utils.hMatt Corallo
2016-12-23Introduce (and use) an IsArgSet accessor methodMatt Corallo
2016-12-23Fix non-const mapMultiArgs[] access after init.Matt Corallo
Swap mapMultiArgs for a const-reference to a _mapMultiArgs which is only accessed in util.cpp
2016-12-23Remove arguments to ParseConfigFileMatt Corallo
2016-12-23Do not evaluate hidden LogPrint argumentsPieter Wuille
2016-12-03Move GetWarnings() into its own file.Gregory Maxwell
2016-12-03Eliminate data races for strMiscWarning and fLargeWork*Found.Gregory Maxwell
This moves all access to these datastructures through accessor functions and protects them with a lock.
2016-12-03Make QT runawayException call GetWarnings instead of directly access ↵Gregory Maxwell
strMiscWarning. This is a first step in avoiding racy accesses to strMiscWarning. The change required moving GetWarnings and related globals to util.
2016-11-29init: Get rid of fServer flagWladimir J. van der Laan
There is no need to store this flag globally, the variable is only used inside the initialization process. Thanks to Alex Morcos for the idea.
2016-10-01Globals: Decouple GetConfigFile and ReadConfigFile from global mapArgsJorge Timón
2016-09-02Do not shadow global variablePavel Janík
2016-06-27util: Remove zero-argument versions of LogPrint and errorWladimir J. van der Laan
Changes in tinyformat, recently imported from upstream have made the zero-argument versions of formatting functions unnecessary. Remove them. This is a slight semantic change: `%` characters in the zero-argument call are now regarded and need to be escaped. As for as I know, the only use of this is in `main.cpp`.
2016-06-01Use std::atomic for fRequestShutdown and fReopenDebugLogPieter Wuille
2016-06-01Revert "Include signal.h for sig_atomic_t in WIN32"Pieter Wuille
This reverts commit 88f14b999cb70f6c556633f2889e698a05305158.
2016-05-27Include signal.h for sig_atomic_t in WIN32Pieter Wuille
2016-05-12Merge #8004: signal handling: fReopenDebugLog and fRequestShutdown should be ↵Wladimir J. van der Laan
type sig_atomic_t 3262316 fReopenDebugLog and fRequestShutdown should be type sig_atomic_t (Chirag Davé)
2016-05-09fReopenDebugLog and fRequestShutdown should be type sig_atomic_tChirag Davé
This allows access as an atomic variable in the presence of async interrupts. See issue #7433 for more details fixes: #7433
2016-05-05don't run ThreadMessageHandler at lowered priorityKaz Wesley
There's no clear reason ThreadMessageHandler should be low priority. Fixes #8010 (priority inversion).
2016-05-04util: switch LogPrint and error to variadic templatesWladimir J. van der Laan
2016-03-11Move GetTempPath() to testutil.Mustafa
2016-02-03Merge branch 'master' into single_prodnameLuke Dashjr
2016-02-03When/if the copyright line does not mention Bitcoin Core developers, add a ↵Luke Dashjr
second line to copyrights in -version, About dialog, and splash screen
2015-12-22Set copyright holders displayed in notices separately from the package nameLuke Dashjr
This helps avoid accidental removal of upstream copyright names
2015-12-13Bump copyright headers to 2015MarcoFalke
2015-11-28[qt] Move GUI related HelpMessage() part downstreamMarcoFalke
2015-11-28[trivial] Reuse translation and cleanup DEFAULT_* valuesMarcoFalke
* DEFAULT_DISABLE_SAFEMODE = false * Use DEFAULT_* constants for extern bools
2015-11-28Constrain constant values to a single location in codeLuke Dashjr
2015-10-26Add option for microsecond precision in debug.logSuhas Daftuar
2015-09-03Move windows socket init to utility functionWladimir J. van der Laan