haolujun opened a new issue, #248:
URL: https://github.com/apache/pulsar-client-cpp/issues/248

   ### Search before asking
   
   - [X] I searched in the 
[issues](https://github.com/apache/pulsar-client-cpp/issues) and found nothing 
similar.
   
   
   ### Version
   
   all version. because I saw that threadSpecificLogPtr in all version code.
   
   ### Minimal reproduce step
   
   May be use a static client.
   
   ### What did you expect to see?
   
   Do not have crash!
   
   ### What did you see instead?
   
   when thread exit and client destory, I called client.close() to close the 
connection. But, got a crash!. I saw the code and added some debug printf, 
finally I found that, threadSpecificLogPtr in ./lib/LogUtils.h is destoryed 
before client close, but thread_local ptr is not null. And then client close 
and may be use threadSpecificLogPtr to log, and at this time got a pointer that 
has been destroyed.  The destroyed order of client and threadSpecificLogPtr is 
not correct. Hope the solution!
   
   ### Anything else?
   
   _No response_
   
   ### Are you willing to submit a PR?
   
   - [ ] I'm willing to submit a PR!


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to