Don't crash when locale is set to Turkish and the user tries to send a mail.

The message id is not that important, since the SMTP server usually also adds
one.

--- kmmessage.cpp       2001/02/24 15:35:55     1.174
+++ kmmessage.cpp       2001/03/08 17:04:22
@@ -990,7 +990,8 @@ void KMMessage::setAutomaticFields(bool
 {
   DwHeaders& header = mMsg->Headers();
   header.MimeVersion().FromString("1.0");
-  header.MessageId().CreateDefault();
+  if (!QString(QTextCodec::locale()).contains("tr_TR")) // crashes otherwise
+    header.MessageId().CreateDefault();

   if (aIsMulti || numBodyParts() > 1)
   {

svn path=/trunk/kdenetwork/kmail/; revision=85958
wilder-work
Michael Haeckel 25 years ago
parent 9e176fc4cb
commit 4e32f24e4b
  1. 3
      kmmessage.cpp

@ -990,7 +990,8 @@ void KMMessage::setAutomaticFields(bool aIsMulti)
{
DwHeaders& header = mMsg->Headers();
header.MimeVersion().FromString("1.0");
header.MessageId().CreateDefault();
if (!QString(QTextCodec::locale()).contains("tr_TR")) // crashes otherwise
header.MessageId().CreateDefault();
if (aIsMulti || numBodyParts() > 1)
{

Loading…
Cancel
Save