Changeset b994034 for protocols/msn/ns.c


Ignore:
Timestamp:
2015-05-31T02:40:05Z (9 years ago)
Author:
dequis <dx@…>
Children:
3c28bd4
Parents:
3fb7139
git-author:
dequis <dx@…> (15-05-15 04:04:28)
git-committer:
dequis <dx@…> (31-05-15 02:40:05)
Message:

msn: check for dead connections in msn_ns_callback

File:
1 edited

Legend:

Unmodified
Added
Removed
  • protocols/msn/ns.c

    r3fb7139 rb994034  
    150150        if (msn_ns_write_cmd(ic, "CNT", "CON", "<connect><ver>2</ver><agent><os>winnt</os><osVer>5.2</osVer><proc>x86</proc><lcid>en-us</lcid></agent></connect>")) {
    151151                if (!md->is_http) {
    152                         md->inpa = b_input_add(md->fd, B_EV_IO_READ, msn_ns_callback, md);
     152                        md->inpa = b_input_add(md->fd, B_EV_IO_READ, msn_ns_callback, ic);
    153153                }
    154154                imcb_log(ic, "Connected to server, waiting for reply");
     
    182182static gboolean msn_ns_callback(gpointer data, gint source, b_input_condition cond)
    183183{
    184         struct msn_data *md = data;
    185         struct im_connection *ic = md->ic;
     184        struct im_connection *ic = data;
     185        struct msn_data *md;
    186186        char *bytes;
    187187        int st;
     188
     189        if (g_slist_find(msn_connections, ic) == NULL) {
     190                return FALSE;
     191        }
     192
     193        md = ic->proto_data;
    188194
    189195        if (md->is_http) {
Note: See TracChangeset for help on using the changeset viewer.