Small changes, essentially cleanup, with no actual code logic change.
* Ensure symbol_buffer aligned same as SYMBOL_INFO
* Use constexpr for compile-time constant
* Use = default for ctor bodies to allow compiler optimize them
* Pass string by reference to prevent copying, other smaller types we can avoid passing by reference as the type is cheaper to copy.
Usage of C++20's new constexpr functionalities for easier usage of custom LEVELS!
Modified:
* With C++20 LEVELS's constructor can have a constexpr specifier
* const LEVELS can be replaced to be constexpr's instead
Improvement for Docker run C++ applications with g3log
* This addresses the case when a PID1 process crashes and the signal handling, goes into multiple or even infinite loops due to subsequent crashes. The PR makes sure to restore all signal handlers to the original signal handling after the first crash is detected. For
* Fix FileSink dropping messages introduced by 'optionable buffer to x messages' feature
Commit 6c6122fafc introduced a bug where 99 out of 100 logs were actually dumped
* Updated unit tests to trigger sink flush bug
---------
Co-authored-by: Ryan Ammoury <ryan.ammoury@squadrone-system.com>
* __SIGFUNC__ no longer default for Windows, It has to be explicitly picked through CMAKE option
* __PRETTY_FUNCTION__ no longer default for gcc/clang, It has to be explicitly picked through CMAKE option
raise() system call does the same as kill() system call in a
single-threaded program.
In a multithreaded program, it does the same as pthread_kill() which
ensures that if the signal causes a handler to be called, raise() will
return only after the signal handler has returned.
When running with additional warnings enabled, a couple lambdas produce
a warning that they should be declared with noexcept. This addresses the
lambdas that had been identified while building.
Signed-off-by: Ben Magistro <koncept1@gmail.com>