aboutsummaryrefslogtreecommitdiffstats
path: root/composer/e-msg-composer.c
diff options
context:
space:
mode:
Diffstat (limited to 'composer/e-msg-composer.c')
-rw-r--r--composer/e-msg-composer.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/composer/e-msg-composer.c b/composer/e-msg-composer.c
index 88cd3190a6..0a72137a24 100644
--- a/composer/e-msg-composer.c
+++ b/composer/e-msg-composer.c
@@ -163,6 +163,9 @@ best_encoding (GByteArray *buf, const char *charset)
int status, count = 0;
iconv_t cd;
+ if (!charset)
+ return -1;
+
cd = iconv_open (charset, "utf-8");
g_return_val_if_fail (cd != (iconv_t)-1, -1);