Hi Andrey,
On 3/1/20, Andrey Semashev via Boost
The right way is to call remove_all_sinks at the end of main, and not use logging after that. E.g. you shouldn't use logging library in global destructors.
That seems working after removing it from the global destructor.
Regarding hanging, you need to investigate what causes the hang.
That fixed hanging after removed remove_all_sinks from the library global destructor, added it to the main of applications.
Also, if you're keeping shared pointers referring to the sink backends, you should reset those pointers before returning from main.
I don't keep shared pointers in applications, it is in the log library, if the instance of the library exits, the shared pointers will be automatically cleaned up. Hope that is a right implementation. Thanks Andrey, Kind regards, - jupiter