The following issue has been SUBMITTED. ====================================================================== http://dbmail.org/mantis/view.php?id=1087 ====================================================================== Reported By: AndroSyn Assigned To: ====================================================================== Project: DBMail Issue ID: 1087 Category: IMAP daemon Reproducibility: always Severity: major Priority: normal Status: new target: ====================================================================== Date Submitted: 22-Aug-17 20:47 CEST Last Modified: 22-Aug-17 20:47 CEST ====================================================================== Summary: When using TLS, the imapd will busy loop endlessly with always write ready sockets Description:
dbmail-imapd will spin with 100% cpu on its main thread due to unnecessary EV_WRITE events being registered for SSL sockets. Since the sockets are always ready, epoll and friends will always return a callback for them. Another related issue to this is, sometimes SSL_write will return SSL_WRITE_WANTS_READ. The correct way to handle this is to call ci_write_cb from insted of the ci_read_cb handler. To tell when we need to do this, I'm setting a bit in the client_state field to mark that we want to read for a write first. The attached patch seems to work for me. ====================================================================== Issue History Date Modified Username Field Change ====================================================================== 22-Aug-17 20:47 AndroSyn New Issue 22-Aug-17 20:47 AndroSyn File Added: dbmail-ssl-spinning.patch ====================================================================== _______________________________________________ Dbmail-dev mailing list Dbmail-dev@dbmail.org http://lists.nfg.nl/mailman/listinfo/dbmail-dev