summaryrefslogtreecommitdiff
path: root/noncore/unsupported
Side-by-side diff
Diffstat (limited to 'noncore/unsupported') (more/less context) (show whitespace changes)
-rw-r--r--noncore/unsupported/mail2/composer.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/noncore/unsupported/mail2/composer.cpp b/noncore/unsupported/mail2/composer.cpp
index 03d50b6..57f0779 100644
--- a/noncore/unsupported/mail2/composer.cpp
+++ b/noncore/unsupported/mail2/composer.cpp
@@ -115,16 +115,17 @@ void Composer::slotSendMail()
for (item = attachView->firstChild(); item != 0; item = item->itemBelow()) {
attachments.append(((AttachViewItem *)item)->attachment());
}
smail.setAttachments(attachments);
QString header, message;
MailFactory::genMail(header, message, smail, this);
+ if (header.isNull() || message.isNull()) return; // Aborted.
abort->setEnabled(true);
SmtpHandler *handler = new SmtpHandler(header, message, accountsLoaded[from->currentItem()], to->text());
connect(handler, SIGNAL(finished()), SLOT(slotSendFinished()));
connect(handler, SIGNAL(error(const QString &)), SLOT(slotSendError(const QString &)));
connect(handler, SIGNAL(status(const QString &)), status, SLOT(setText(const QString &)));
}