I found a Bug in SIPHandler::OnTransactionFailed, when the reliable transport is lost. SIPTransaction::SetTerminated removes itself from the list of active transactions of the transaction owner and then calls OnTransactionFailed. In SIPHandler::OnTransactionFailed this transaction shall be deleted again, which will fail. This causes the register thread to hang. It never terminates and I cannot detect that error.
I attached a possible patch for that.