aboutsummaryrefslogtreecommitdiffstats
path: root/camel
diff options
context:
space:
mode:
authorJeffrey Stedfast <fejj@ximian.com>2001-10-11 05:36:22 +0800
committerJeffrey Stedfast <fejj@src.gnome.org>2001-10-11 05:36:22 +0800
commite055b4a0fdb344ec82eb13a6c8b059621e1b8f85 (patch)
treef60cc79d716aaf7e6d0874e8bf171a12f0c18925 /camel
parent82b63c067c1e3e1b7018154e3c6c05f96956fbdd (diff)
downloadgsoc2013-evolution-e055b4a0fdb344ec82eb13a6c8b059621e1b8f85.tar.gz
gsoc2013-evolution-e055b4a0fdb344ec82eb13a6c8b059621e1b8f85.tar.zst
gsoc2013-evolution-e055b4a0fdb344ec82eb13a6c8b059621e1b8f85.zip
Added a hack for Solaris systems.
2001-10-10 Jeffrey Stedfast <fejj@ximian.com> * camel-charset-map.c (camel_charset_map_init): Added a hack for Solaris systems. svn path=/trunk/; revision=13569
Diffstat (limited to 'camel')
-rw-r--r--camel/ChangeLog5
-rw-r--r--camel/camel-charset-map.c9
2 files changed, 11 insertions, 3 deletions
diff --git a/camel/ChangeLog b/camel/ChangeLog
index 7c865fe1ad..f994e8430f 100644
--- a/camel/ChangeLog
+++ b/camel/ChangeLog
@@ -1,3 +1,8 @@
+2001-10-10 Jeffrey Stedfast <fejj@ximian.com>
+
+ * camel-charset-map.c (camel_charset_map_init): Added a hack for
+ Solaris systems.
+
2001-10-10 <NotZed@Ximian.com>
* providers/local/camel-maildir-store.c (scan_dir): oops, we want
diff --git a/camel/camel-charset-map.c b/camel/camel-charset-map.c
index 39904b71e3..fd530165ed 100644
--- a/camel/camel-charset-map.c
+++ b/camel/camel-charset-map.c
@@ -262,7 +262,7 @@ struct {
charsets, but we have code that will parse and convert them
to their cp#### equivalents if/when they show up in
camel_charset_map_to_iconv() so I'm not going to bother
- putting them all in here... */
+ putting them all in here either... */
{ "ks_c_5601-1987", "euc-kr" },
{ NULL, NULL }
};
@@ -326,9 +326,9 @@ camel_charset_map_init (void)
g_hash_table_insert (iconv_charsets, g_strdup (known_iconv_charsets[i].charset),
g_strdup (known_iconv_charsets[i].iconv_name));
}
-
+
e_dlist_init(&iconv_cache_list);
-
+
locale = setlocale (LC_ALL, NULL);
if (!locale || !strcmp (locale, "C") || !strcmp (locale, "POSIX")) {
@@ -349,6 +349,9 @@ camel_charset_map_init (void)
int len;
p = strchr (locale, '@');
+ if (p == NULL)
+ p = strchr (locale, '/'); /* This is a hack for Solaris systems */
+
len = p ? (p - locale) : strlen (locale);
if ((p = strchr (locale, '.'))) {
locale_charset = g_strndup (p + 1, len - (p - locale) + 1);