Version: unspecified OS: Linux Line 528 of ChatWidget.cpp calls sendMessage() however we not check the PendingSendMessage() to see if the operations succeeded. Reproducible: Always
The problem is wider than that. Just checking for errors from the Tp::PendingSendMessage returned by Tp::TextChannel::send isn't enough (though I guess we could want to check for that, too). From #kde-telepathy, Mar 30 2011: 20:58 < oggis_> lliehu: actually TextChannel::sendMessage only fails if the message is somehow malformed or alike - you receive a special message which is the delivery report later on, linked by the token you get from the PendingSendMessage I'm not sure if delivery reports are received by Tp::TextChannel::messageReceived, just with Tp::Message::messageType() returning Tp::ChannelTextMessageTypeDeliveryReport, as I haven't been able to receive a delivery report (haven't tried that hard, though).
Created attachment 59031 [details] Check for delivery reports (not-so-pretty patch) With this, an example "steps to reproduce" a delivery report: 1. Chat with someone on MSN using telepathy-haze. 2. block msn using iptables 3. send some messages and then wait 4. output on console: telepathy-kde-text-ui(9956) ChatWidget::handleIncomingMessage: Received a delivery report! telepathy-kde-text-ui(9956) ChatWidget::handleIncomingMessage: delivery failed temporarily telepathy-kde-text-ui(9956) ChatWidget::handleIncomingMessage: Delivery report for message: "" ; sent at QDateTime("") telepathy-kde-text-ui(9956) ChatWidget::handleIncomingMessage: "Lasse" "Message could not be sent because an error with the switchboard occurred:"
We now catch message failed reports. Resolved.