aboutsummaryrefslogtreecommitdiffstats
path: root/composer
diff options
context:
space:
mode:
authorJeffrey Stedfast <fejj@ximian.com>2003-06-19 01:57:01 +0800
committerJeffrey Stedfast <fejj@src.gnome.org>2003-06-19 01:57:01 +0800
commit13f8e60e3a60f9f55bd1b06dc78574b1840b3922 (patch)
tree01ec8211728db938547cbe0d1738431c31954dd4 /composer
parent9875794a7150d6ffa13fdd9cddcca0c2edb2666e (diff)
downloadgsoc2013-evolution-13f8e60e3a60f9f55bd1b06dc78574b1840b3922.tar.gz
gsoc2013-evolution-13f8e60e3a60f9f55bd1b06dc78574b1840b3922.tar.zst
gsoc2013-evolution-13f8e60e3a60f9f55bd1b06dc78574b1840b3922.zip
Use e_iconv_open/close so that we get charset aliasing for free. Fixes bug
2003-06-17 Jeffrey Stedfast <fejj@ximian.com> * e-msg-composer.c (best_encoding): Use e_iconv_open/close so that we get charset aliasing for free. Fixes bug #44991. svn path=/trunk/; revision=21469
Diffstat (limited to 'composer')
-rw-r--r--composer/ChangeLog5
-rw-r--r--composer/e-msg-composer.c6
2 files changed, 8 insertions, 3 deletions
diff --git a/composer/ChangeLog b/composer/ChangeLog
index baff4a25b2..3a6376402e 100644
--- a/composer/ChangeLog
+++ b/composer/ChangeLog
@@ -1,3 +1,8 @@
+2003-06-17 Jeffrey Stedfast <fejj@ximian.com>
+
+ * e-msg-composer.c (best_encoding): Use e_iconv_open/close so that
+ we get charset aliasing for free. Fixes bug #44991.
+
2003-06-16 Jeffrey Stedfast <fejj@ximian.com>
Fixes bug #44139.
diff --git a/composer/e-msg-composer.c b/composer/e-msg-composer.c
index 18cf3382e0..661d875a74 100644
--- a/composer/e-msg-composer.c
+++ b/composer/e-msg-composer.c
@@ -202,7 +202,7 @@ best_encoding (GByteArray *buf, const char *charset)
if (!charset)
return -1;
- cd = iconv_open (charset, "utf-8");
+ cd = e_iconv_open (charset, "utf-8");
if (cd == (iconv_t) -1)
return -1;
@@ -211,13 +211,13 @@ best_encoding (GByteArray *buf, const char *charset)
do {
out = outbuf;
outlen = sizeof (outbuf);
- status = iconv (cd, &in, &inlen, &out, &outlen);
+ status = e_iconv (cd, &in, &inlen, &out, &outlen);
for (ch = out - 1; ch >= outbuf; ch--) {
if ((unsigned char)*ch > 127)
count++;
}
} while (status == (size_t) -1 && errno == E2BIG);
- iconv_close (cd);
+ e_iconv_close (cd);
if (status == (size_t) -1)
return -1;