Ignore:
Timestamp:
2015-03-12T09:10:16Z (10 years ago)
Author:
dequis <dx@…>
Children:
fc650a8
Parents:
0e4c3dd (diff), 3bb333c (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

Merge branch 'develop' into feat/hip-cat

File:
1 edited

Legend:

Unmodified
Added
Removed
  • protocols/msn/msn.c

    r0e4c3dd r89db90e  
    4141        s->flags |= SET_NOSAVE | ACC_SET_ONLINE_ONLY;
    4242
    43         s = set_add(&acc->set, "server", MSN_NS_HOST, set_eval_account, acc);
     43        s = set_add(&acc->set, "server", NULL, set_eval_account, acc);
    4444        s->flags |= SET_NOSAVE | ACC_SET_OFFLINE_ONLY;
    4545
     
    5858        struct im_connection *ic = imcb_new(acc);
    5959        struct msn_data *md = g_new0(struct msn_data, 1);
     60        char *server = set_getstr(&ic->acc->set, "server");
    6061
    6162        ic->proto_data = md;
    6263        ic->flags |= OPT_PONGS | OPT_PONGED;
     64
     65        if (!server) {
     66                imcb_error(ic, "The msn protocol is disabled in this version because most servers disabled MSNP18 over port 1863.");
     67                imcb_error(ic, "If you find a working server, you can change the 'server' setting of this account. Good luck!");
     68                imcb_error(ic, "See also: http://ismsndeadyet.com/"); // shameless plug
     69                imc_logout(ic, FALSE);
     70                return;
     71        }
    6372
    6473        if (strchr(acc->user, '@') == NULL) {
     
    7685
    7786        imcb_log(ic, "Connecting");
    78         msn_ns_connect(ic, md->ns,
    79                        set_getstr(&ic->acc->set, "server"),
     87        msn_ns_connect(ic, md->ns, server,
    8088                       set_getint(&ic->acc->set, "port"));
    8189}
     
    112120                while (md->groups) {
    113121                        struct msn_group *mg = md->groups->data;
     122                        md->groups = g_slist_remove(md->groups, mg);
    114123                        g_free(mg->id);
    115124                        g_free(mg->name);
    116125                        g_free(mg);
    117                         md->groups = g_slist_remove(md->groups, mg);
    118126                }
    119127
     
    127135                while (md->grpq) {
    128136                        struct msn_groupadd *ga = md->grpq->data;
     137                        md->grpq = g_slist_remove(md->grpq, ga);
    129138                        g_free(ga->group);
    130139                        g_free(ga->who);
    131140                        g_free(ga);
    132                         md->grpq = g_slist_remove(md->grpq, ga);
    133141                }
    134142
Note: See TracChangeset for help on using the changeset viewer.