HardySimpson / zlog

A reliable, high-performance, thread safe, flexsible, clear-model, pure C logging library.
Apache License 2.0
2.25k stars 721 forks source link

Fix zlog_env_conf concurrency question #269

Closed breadmechanic closed 2 months ago

breadmechanic commented 2 months ago

Log printing interfaces, such as zlog and vzlog, do not invoke zlog_env_lock to lock when accessing zlog_env_conf.

However, the zlog_reload interface deletes zlog_env_conf from the lock. As a result, a null pointer error occurs.

deemar commented 2 months ago

Merged Thank you very much!

breadmechanic commented 2 months ago

Thank you