Changes in protocols/yahoo/libyahoo2.c [d7edadf:241f9f6]
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
protocols/yahoo/libyahoo2.c
rd7edadf r241f9f6 1809 1809 struct yahoo_input_data *yid = had->yid; 1810 1810 struct yahoo_data *yd = yid->yd; 1811 struct http_request *req; 1811 1812 char *login, *passwd, *chal; 1812 1813 char *url; … … 1822 1823 (int) time(NULL), login, passwd, chal); 1823 1824 1824 http_dorequest_url(url, yahoo_https_auth_token_finish, had);1825 req = http_dorequest_url(url, yahoo_https_auth_token_finish, had); 1825 1826 1826 1827 g_free(url); … … 1869 1870 static void yahoo_https_auth_init(struct yahoo_https_auth_data *had) 1870 1871 { 1872 struct http_request *req; 1871 1873 char *url; 1872 1874 … … 1874 1876 (int) time(NULL), had->token); 1875 1877 1876 http_dorequest_url(url, yahoo_https_auth_finish, had);1878 req = http_dorequest_url(url, yahoo_https_auth_finish, had); 1877 1879 1878 1880 g_free(url); … … 1988 1990 { 1989 1991 struct yahoo_data *yd = yid->yd; 1992 char *login_id; 1993 char *handle; 1990 1994 char *url = NULL; 1991 1995 int login_status = -1; … … 1996 2000 struct yahoo_pair *pair = l->data; 1997 2001 if (pair->key == 0) 1998 ; /* login_id */2002 login_id = pair->value; 1999 2003 else if (pair->key == 1) 2000 ; /* handle */2004 handle = pair->value; 2001 2005 else if (pair->key == 20) 2002 2006 url = pair->value; … … 2085 2089 char *msg = NULL; 2086 2090 char *name = NULL; 2091 long tm = 0L; 2087 2092 int state = YAHOO_STATUS_AVAILABLE; 2093 int online = 0; 2088 2094 int away = 0; 2089 2095 int idle = 0; … … 2105 2111 state = strtol(pair->value, NULL, 10); 2106 2112 else if (pair->key == 15) 2107 ; /* tm */2113 tm = strtol(pair->value, NULL, 10); 2108 2114 else if (pair->key == 13) 2109 ; /* online */2115 online = strtol(pair->value, NULL, 10); 2110 2116 else if (pair->key == 47) 2111 2117 away = strtol(pair->value, NULL, 10); … … 2134 2140 char *where = NULL; 2135 2141 int status = 0; 2142 char *me = NULL; 2136 2143 2137 2144 struct yahoo_buddy *bud = NULL; … … 2141 2148 struct yahoo_pair *pair = l->data; 2142 2149 if (pair->key == 1) 2143 ; /* Me... don't care */2150 me = pair->value; 2144 2151 if (pair->key == 7) 2145 2152 who = pair->value; … … 2197 2204 char *who = NULL; 2198 2205 char *where = NULL; 2206 int unk_66 = 0; 2207 char *me = NULL; 2199 2208 struct yahoo_buddy *bud; 2200 2209 … … 2205 2214 struct yahoo_pair *pair = l->data; 2206 2215 if (pair->key == 1) 2207 ; /* Me... don't care */2216 me = pair->value; 2208 2217 else if (pair->key == 7) 2209 2218 who = pair->value; … … 2211 2220 where = pair->value; 2212 2221 else if (pair->key == 66) 2213 ; /* unk_66 */2222 unk_66 = strtol(pair->value, NULL, 10); 2214 2223 else 2215 2224 DEBUG_MSG(("unknown key: %d = %s", pair->key, … … 2247 2256 struct yahoo_packet *pkt) 2248 2257 { 2258 char *who = NULL; 2259 int status = 0; 2260 char *me = NULL; 2261 int un_ignore = 0; 2262 2249 2263 YList *l; 2250 2264 for (l = pkt->hash; l; l = l->next) { 2251 2265 struct yahoo_pair *pair = l->data; 2252 2266 if (pair->key == 0) 2253 ; /* who */2267 who = pair->value; 2254 2268 if (pair->key == 1) 2255 ; /* Me... don't care */2269 me = pair->value; 2256 2270 if (pair->key == 13) /* 1 == ignore, 2 == unignore */ 2257 ;2271 un_ignore = strtol(pair->value, NULL, 10); 2258 2272 if (pair->key == 66) 2259 ; /* status */2273 status = strtol(pair->value, NULL, 10); 2260 2274 } 2261 2275 … … 2279 2293 char *me = NULL; 2280 2294 char *room = NULL; 2295 char *voice_room = NULL; 2281 2296 2282 2297 YList *l; … … 2288 2303 me = pair->value; 2289 2304 if (pair->key == 13) 2290 ; /* voice room */2305 voice_room = pair->value; 2291 2306 if (pair->key == 57) 2292 2307 room = pair->value; … … 2423 2438 struct yahoo_packet *pkt) 2424 2439 { 2440 char *me = NULL; 2425 2441 char *key = NULL; 2426 2442 char *who = NULL; … … 2431 2447 struct yahoo_pair *pair = l->data; 2432 2448 if (pair->key == 5) 2433 ; /* me */2449 me = pair->value; 2434 2450 if (pair->key == 61) 2435 2451 key = pair->value; … … 3353 3369 struct yahoo_webcam *wcm = y->wcm; 3354 3370 struct yahoo_input_data *yid; 3371 struct yahoo_server_settings *yss; 3355 3372 3356 3373 if (!wcm || !wcm->server || !wcm->key) … … 3364 3381 yid->wcm = y->wcm; 3365 3382 y->wcm = NULL; 3383 3384 yss = y->yd->server_settings; 3366 3385 3367 3386 yid->wcd = y_new0(struct yahoo_webcam_data, 1); … … 4956 4975 YList *l; 4957 4976 struct send_file_data *sfd; 4977 char *who = NULL; 4978 char *filename = NULL; 4958 4979 char *id = NULL; 4959 4980 char *token = NULL; … … 4963 4984 switch (pair->key) { 4964 4985 case 4: 4965 /* who */4986 who = pair->value; 4966 4987 break; 4967 4988 case 5: … … 4977 4998 break; 4978 4999 case 27: 4979 /* filename */5000 filename = pair->value; 4980 5001 break; 4981 5002 } … … 5002 5023 { 5003 5024 YList *l; 5025 char *who = NULL; 5026 char *filename = NULL; 5004 5027 char *id = NULL; 5005 5028 char *token = NULL; … … 5013 5036 case 1: 5014 5037 case 4: 5015 /* who */5038 who = pair->value; 5016 5039 break; 5017 5040 case 5: … … 5030 5053 break; 5031 5054 case 27: 5032 /* filename */5055 filename = pair->value; 5033 5056 break; 5034 5057 }
Note: See TracChangeset
for help on using the changeset viewer.