Closed joshorenberg closed 1 year ago
I found a workaround for the error... I offloaded the email sending code to a worker thread (which is what I wanted in the first place) and everything is working now, no more crashes. Weird...
It's back! I merged in the email code branch and am getting the same crash now even in the worker thread. However if I run using the simplemail .lib file built in debug mode instead of release mode and run the program in debug mode the program doesn't crash.
And another possibly important piece of information... I tried using Bluetiger9 for email as well (another email library for Qt) and got a very similar crash with an almost identical backtrace. See here: https://github.com/bluetiger9/SmtpClient-for-Qt/issues/123
I suggest you look at the lifetime of your objects! Sending an email is an asynchronous operation. You must not (implicitely) delete memory while in an event loop. It is likely that while you wait for your mail to be delivered, some other event kicks in (and is processed) that tempers with your memory. The SmtpClient4Qt works fine with a similar code, btw.
Sender is async you are just deleting it before it has a chance to work.
blocking mode is unsupported on v3
Hi I have the same problem as issue #80 after modifying the code as mentioned. By no means do I mean to rush you to fix this; please do on your own time, I just thought you didn't see my other post. Thanks! Backtrace on bottom.