Best method for silent exception handling
Re: Best method for silent exception handling
How is that data stored? Can you access it in a thread safe way?
Of course you could just ignore the danger of multi-threading and access the data directly. In most cases your exception handler will be called in the context of the main thread (if you use "trySync"), anyway.
Of course you could just ignore the danger of multi-threading and access the data directly. In most cases your exception handler will be called in the context of the main thread (if you use "trySync"), anyway.
Re: Best method for silent exception handling
No.madshi wrote:How is that data stored? Can you access it in a thread safe way?
What do you mean with "trySync"? I think you mean "stTrySyncCallAlways", right?madshi wrote:Of course you could just ignore the danger of multi-threading and access the data directly. In most cases your exception handler will be called in the context of the main thread (if you use "trySync"), anyway.
Re: Best method for silent exception handling
Yes, that's what I meant.
Re: Best method for silent exception handling
Thank you for your assistance!
Re: Best method for silent exception handling
It runs in that secondary thread.madshi wrote:What does EurekaLog do if the exception was raised by a secondary thread?
No.madshi wrote:Is your exception callback still called within the context of the main thread?
... and the exception dialog ("MSClassics") uses the VCL.
(EurekaLog 7.5.)
Re: Best method for silent exception handling
In my tests showing a VCL form in a secondary thread resulted in all sorts of problems. The VCL simply isn't thread safe. If EurekaLog does show a VCL form in a secondary thread, I can only imagine that it can't be perfectly stable.
Re: Best method for silent exception handling
I agree with you: This solution of EurekaLog is bad. Your solution is much better! ... I wanted to let you know this...madshi wrote:If EurekaLog does show a VCL form in a secondary thread, I can only imagine that it can't be perfectly stable.
Re: Best method for silent exception handling
Thanks, that's good to know!