diff options
author | Larry Ewing <lewing@ximian.com> | 2001-07-07 06:20:34 +0800 |
---|---|---|
committer | Larry Ewing <lewing@src.gnome.org> | 2001-07-07 06:20:34 +0800 |
commit | 2caec09b47fe3d60677c8e4439b78abd6cf7888e (patch) | |
tree | 30b5fc3402ea8af26178a7932e6463de4cf74069 | |
parent | 90f4c18deb4736515b19732ebc33cc65c2b14cf6 (diff) | |
download | gsoc2013-evolution-2caec09b47fe3d60677c8e4439b78abd6cf7888e.tar gsoc2013-evolution-2caec09b47fe3d60677c8e4439b78abd6cf7888e.tar.gz gsoc2013-evolution-2caec09b47fe3d60677c8e4439b78abd6cf7888e.tar.bz2 gsoc2013-evolution-2caec09b47fe3d60677c8e4439b78abd6cf7888e.tar.lz gsoc2013-evolution-2caec09b47fe3d60677c8e4439b78abd6cf7888e.tar.xz gsoc2013-evolution-2caec09b47fe3d60677c8e4439b78abd6cf7888e.tar.zst gsoc2013-evolution-2caec09b47fe3d60677c8e4439b78abd6cf7888e.zip |
(best_encoding): make sure we don't try to call iconv_open with a NULL
2001-07-06 Larry Ewing <lewing@ximian.com>
(best_encoding): make sure we don't try to call iconv_open with a
NULL tocode.
svn path=/trunk/; revision=10872
-rw-r--r-- | composer/ChangeLog | 2 | ||||
-rw-r--r-- | composer/e-msg-composer.c | 3 |
2 files changed, 5 insertions, 0 deletions
diff --git a/composer/ChangeLog b/composer/ChangeLog index 14aeb9c916..f4b312f00e 100644 --- a/composer/ChangeLog +++ b/composer/ChangeLog @@ -1,6 +1,8 @@ 2001-07-06 Larry Ewing <lewing@ximian.com> * e-msg-composer.c (autosave_manager_new): add missing static. + (best_encoding): make sure we don't try to call iconv_open with a + NULL tocode. 2001-07-06 Jeffrey Stedfast <fejj@ximian.com> 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); |