diff options
| author | dequis <dx@dxzone.com.ar> | 2015-02-28 20:15:56 -0300 | 
|---|---|---|
| committer | dequis <dx@dxzone.com.ar> | 2015-02-28 20:17:33 -0300 | 
| commit | a6b00fcae9af439133a342741e80463db994d620 (patch) | |
| tree | 5aa07f4ab64b9f248e592137a36fdd4e80e048b2 /protocols | |
| parent | a880e34c6aeba0775875e3113ff84d6d46fd5d49 (diff) | |
Disable msn by default :(
I didn't want to do the next release with a broken msn, but...
gotta be realistic.
Also featuring shameless plug.
Diffstat (limited to 'protocols')
| -rw-r--r-- | protocols/msn/msn.c | 14 | 
1 files changed, 11 insertions, 3 deletions
| diff --git a/protocols/msn/msn.c b/protocols/msn/msn.c index cb3f842c..1f2dfe3e 100644 --- a/protocols/msn/msn.c +++ b/protocols/msn/msn.c @@ -40,7 +40,7 @@ static void msn_init(account_t *acc)  	s = set_add(&acc->set, "display_name", NULL, set_eval_display_name, acc);  	s->flags |= SET_NOSAVE | ACC_SET_ONLINE_ONLY; -	s = set_add(&acc->set, "server", MSN_NS_HOST, set_eval_account, acc); +	s = set_add(&acc->set, "server", NULL, set_eval_account, acc);  	s->flags |= SET_NOSAVE | ACC_SET_OFFLINE_ONLY;  	s = set_add(&acc->set, "port", MSN_NS_PORT, set_eval_int, acc); @@ -57,10 +57,19 @@ static void msn_login(account_t *acc)  {  	struct im_connection *ic = imcb_new(acc);  	struct msn_data *md = g_new0(struct msn_data, 1); +	char *server = set_getstr(&ic->acc->set, "server");  	ic->proto_data = md;  	ic->flags |= OPT_PONGS | OPT_PONGED; +	if (!server) { +		imcb_error(ic, "The msn protocol is disabled in this version because most servers disabled MSNP18 over port 1863."); +		imcb_error(ic, "If you find a working server, you can change the 'server' setting of this account. Good luck!"); +		imcb_error(ic, "See also: http://ismsndeadyet.com/"); // shameless plug +		imc_logout(ic, FALSE); +		return; +	} +  	if (strchr(acc->user, '@') == NULL) {  		imcb_error(ic, "Invalid account name");  		imc_logout(ic, FALSE); @@ -75,8 +84,7 @@ static void msn_login(account_t *acc)  	msn_connections = g_slist_prepend(msn_connections, ic);  	imcb_log(ic, "Connecting"); -	msn_ns_connect(ic, md->ns, -	               set_getstr(&ic->acc->set, "server"), +	msn_ns_connect(ic, md->ns, server,  	               set_getint(&ic->acc->set, "port"));  } | 
