summary refs log tree commit diff stats
path: root/src/common
diff options
context:
space:
mode:
authorArnavion <arnavion@gmail.com>2015-01-31 00:52:30 -0800
committerArnavion <arnavion@gmail.com>2015-01-31 00:52:30 -0800
commit5dde0d7c6d703a6797cbe3af8aa548ba23a1a024 (patch)
tree71021f9926d41fa97402d904e10d0c7e78b5eee0 /src/common
parent9968bb31a45bb123de69ad7be1a3cafab86901e4 (diff)
Also verify encoding read from servlist.conf
Diffstat (limited to 'src/common')
-rw-r--r--src/common/servlist.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/common/servlist.c b/src/common/servlist.c
index 4951d4e5..92016366 100644
--- a/src/common/servlist.c
+++ b/src/common/servlist.c
@@ -1050,7 +1050,7 @@ servlist_load (void)
 				net->logintype = atoi (buf + 2);
 				break;
 			case 'E':
-				net->encoding = g_strdup (buf + 2);
+				net->encoding = servlist_check_encoding (buf + 2) ? g_strdup (buf + 2) : g_strdup ("UTF-8");
 				break;
 			case 'F':
 				net->flags = atoi (buf + 2);