xietangxin dc561451d7 imjournal: fix double sd_journal_close() during thread cancellation
When the main thread cancel imjournal thread, the thread exits without
setting sd_journal to NULL because sd_journal_close() contain cancel point.
This leads to a double free scenario where:

1. The thread cancel occurs during sd_journal_close()
2. The main thread then calls imjournal's afterrun function
3. sd_journal_close() is called again on the already-freed sd_journal
2025-08-18 20:14:09 +08:00
..