James O'Beirne
383b186c28
threads: prefix log messages with thread names
...
Introduce a new flag (`-logthreadnames`) which allows toggling
of this behavior.
2019-04-29 13:49:15 -04:00
MarcoFalke
77777c5624
log: Construct global logger on first use
2019-01-29 15:30:24 -05:00
MarcoFalke
fae3fbd61a
logging: Replace LogPrint macros with regular functions
2018-09-12 11:28:01 -04:00
practicalswift
0bd4cd398b
logging: remove unused return value from LogPrintStr
...
`LogPrintStr` returns the number of characters printed. This number is
doubled if both logging to console and logging to file is enabled. As
the return value is never used, I've opted to remove it instead of try
to fix it.
Credit: @laanwj
2018-05-02 11:25:20 +02:00
Jim Posen
8c2d695c4a
util: Store debug log file path in BCLog::Logger member.
...
This breaks the cyclic between logging and util.
2018-04-29 14:37:19 -07:00
Jim Posen
8e7b961388
scripted-diff: Rename BCLog::Logger member variables.
...
-BEGIN VERIFY SCRIPT-
sed -i "s/fileout/m_fileout/" src/logging.h src/logging.cpp
sed -i "s/mutexDebugLog/m_file_mutex/" src/logging.h src/logging.cpp
sed -i "s/vMsgsBeforeOpenLog/m_msgs_before_open/" src/logging.h src/logging.cpp
sed -i "s/logCategories/m_categories/" src/logging.h src/logging.cpp
sed -i "s/fPrintToConsole/m_print_to_console/" src/logging.h src/logging.cpp src/init.cpp
sed -i "s/fPrintToDebugLog/m_print_to_file/" src/logging.h src/logging.cpp src/init.cpp src/test/test_bitcoin.cpp src/bench/bench_bitcoin.cpp
sed -i "s/fLogTimestamps/m_log_timestamps/" src/logging.h src/logging.cpp src/init.cpp
sed -i "s/fLogTimeMicros/m_log_time_micros/" src/logging.h src/logging.cpp src/init.cpp
sed -i "s/fReopenDebugLog/m_reopen_file/" src/logging.h src/logging.cpp src/init.cpp
sed -i "s/fStartedNewLine/m_started_new_line/" src/logging.h src/logging.cpp
-END VERIFY SCRIPT-
2018-04-29 14:37:17 -07:00
Jim Posen
1eac317f25
util: Refactor GetLogCategory.
...
Changing parameter types from pointers to references and uint32_t to
BCLog::LogFlags simplies calling code.
2018-04-29 14:37:17 -07:00
Jim Posen
3316a9ebb6
util: Encapsulate logCategories within BCLog::Logger.
2018-04-27 16:10:02 -07:00
Jim Posen
6a6d764ca5
util: Move debug file management functions into Logger.
2018-04-27 16:10:00 -07:00
Jim Posen
f55f4fcf05
util: Establish global logger object.
...
The object encapsulates logging configuration, and in a later commit,
set up routines will also be moved into the class.
2018-04-27 16:09:59 -07:00
Jim Posen
b77b6e2345
MOVEONLY: Move logging code from util.{h,cpp} to new files.
2018-04-18 10:05:05 -07:00