]> saetta.ns0.it Git - solipa/libsolipa/commitdiff
SolipaMail: impostato utf8 come charset.
authorAndrea Zagli <azagli@libero.it>
Tue, 11 Nov 2014 14:01:40 +0000 (15:01 +0100)
committerAndrea Zagli <azagli@libero.it>
Tue, 11 Nov 2014 14:01:40 +0000 (15:01 +0100)
src/mail.c

index 7d94334e530a709ac2892ef166f8adcfb7a82870..e298367b7fd802045289d5d8f5e480ef8ec3cc89 100644 (file)
@@ -324,12 +324,12 @@ static CamelMimeMessage
            && priv->body_html != NULL)
                {
                        part = camel_mime_part_new ();
-                       camel_mime_part_set_content (part, priv->body_plain, strlen (priv->body_plain), "text/plain");
+                       camel_mime_part_set_content (part, priv->body_plain, strlen (priv->body_plain), "text/plain; charset=\"UTF-8\"");
                        camel_multipart_add_part (mp, part);
                        g_object_unref (part);
 
                        part = camel_mime_part_new ();
-                       camel_mime_part_set_content (part, priv->body_html, strlen (priv->body_html), "text/html");
+                       camel_mime_part_set_content (part, priv->body_html, strlen (priv->body_html), "text/html; charset=\"UTF-8\"");
                        camel_multipart_add_part (mp, part);
                        g_object_unref (part);
                }
@@ -346,11 +346,11 @@ static CamelMimeMessage
 
                        if (priv->body_plain != NULL)
                                {
-                                       camel_mime_part_set_content (CAMEL_MIME_PART (part), priv->body_plain, strlen (priv->body_plain), "text/plain");
+                                       camel_mime_part_set_content (CAMEL_MIME_PART (part), priv->body_plain, strlen (priv->body_plain), "text/plain; charset=\"UTF-8\"");
                                }
                        else if (priv->body_html != NULL)
                                {
-                                       camel_mime_part_set_content (CAMEL_MIME_PART (part), priv->body_html, strlen (priv->body_html), "text/html");
+                                       camel_mime_part_set_content (CAMEL_MIME_PART (part), priv->body_html, strlen (priv->body_html), "text/html; charset=\"UTF-8\"");
                                }
 
                        if (mp != NULL)