diff options
author | Arnavion <arnavion@gmail.com> | 2015-01-18 02:10:04 -0800 |
---|---|---|
committer | Arnavion <arnavion@gmail.com> | 2015-01-18 02:10:04 -0800 |
commit | 5749c53484369515c4e6df4a4730b1f34fab82b4 (patch) | |
tree | 8ba88feef1e6086981f8add539572d6cd0b142c2 /src/common/text.h | |
parent | 5569205d1578f46a4ba4a2b23d8e48a933acd6ce (diff) |
Server line text-encoding-related fixes.
- Handle server lines that contain sequences which are invalid in the server encoding. Previously, these would cause the whole line to be interpreted in ISO-8859-1, but now they're simply replaced with an appropriate replacement character. - Removed prefs.utf8_locale. - Change default server encoding from system locale to UTF-8. - Always populate server->encoding with a non-null value - UTF-8. Fixes #1198
Diffstat (limited to 'src/common/text.h')
-rw-r--r-- | src/common/text.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/common/text.h b/src/common/text.h index 2534187e..4f47815d 100644 --- a/src/common/text.h +++ b/src/common/text.h @@ -57,7 +57,8 @@ void text_emit (int index, session *sess, char *a, char *b, char *c, char *d, time_t timestamp); int text_emit_by_name (char *name, session *sess, time_t timestamp, char *a, char *b, char *c, char *d); -char *text_validate (char **text, gssize *len); +gchar *text_invalid_utf8_to_encoding (const gchar* text, gssize len, const gchar *to_encoding, gsize *len_out); +gchar *text_invalid_encoding_to_utf8 (const gchar* text, gssize len, const gchar *from_encoding, gsize *len_out); int get_stamp_str (char *fmt, time_t tim, char **ret); void format_event (session *sess, int index, char **args, char *o, gsize sizeofo, unsigned int stripcolor_args); char *text_find_format_string (char *name); |