Mercurial > pidgin
comparison src/protocols/yahoo/ycht.c @ 11318:519dc2186438
[gaim-migrate @ 13521]
Bits and pieces all over the place. I was hunting down compiler warnings
all over the place, with crazy CFLAGS. I think I might have got a bit
carried away.
I made the perl stuff compile with gcc 2.x (which don't support
mixed declerations and statements), I think what I did was safe but
readily admit I have no clue how all the perl stuff works.
Rename gaim_presence_add_presence() to gaim_presence_add_list() (to match
the header file - obviously nothing actually _uses_ this)
Implement gaim_savedstatus_get_handle() because it's in the header file.
Remove gaim_account_set_presence() from account.h - it's not actually
implemented anywhere, so it can't be that important.
committer: Tailor Script <tailor@pidgin.im>
author | Stu Tomlinson <stu@nosnilmot.com> |
---|---|
date | Sat, 20 Aug 2005 20:17:08 +0000 |
parents | a8f9e5ce4f92 |
children | f4e58e94ced3 |
comparison
equal
deleted
inserted
replaced
11317:cdd9d1011d97 | 11318:519dc2186438 |
---|---|
191 } | 191 } |
192 | 192 |
193 /***************************************************************************** | 193 /***************************************************************************** |
194 * Functions dealing with YCHT packets and their contents directly. | 194 * Functions dealing with YCHT packets and their contents directly. |
195 *****************************************************************************/ | 195 *****************************************************************************/ |
196 static void ycht_packet_dump(const char *data, int len) | 196 static void ycht_packet_dump(const guchar *data, int len) |
197 { | 197 { |
198 #ifdef YAHOO_YCHT_DEBUG | 198 #ifdef YAHOO_YCHT_DEBUG |
199 int i; | 199 int i; |
200 | 200 |
201 gaim_debug(GAIM_DEBUG_MISC, "yahoo", ""); | 201 gaim_debug(GAIM_DEBUG_MISC, "yahoo", ""); |
429 gint status; | 429 gint status; |
430 | 430 |
431 if (ycht->rxlen < YCHT_HEADER_LEN) | 431 if (ycht->rxlen < YCHT_HEADER_LEN) |
432 return; | 432 return; |
433 | 433 |
434 if (strncmp("YCHT", ycht->rxqueue, 4) != 0) | 434 if (strncmp("YCHT", (char *)ycht->rxqueue, 4) != 0) |
435 gaim_debug_error("yahoo", "YCHT: protocol error.\n"); | 435 gaim_debug_error("yahoo", "YCHT: protocol error.\n"); |
436 | 436 |
437 pos += 4; /* YCHT */ | 437 pos += 4; /* YCHT */ |
438 | 438 |
439 version = yahoo_get32(ycht->rxqueue + pos); pos += 4; | 439 version = yahoo_get32(ycht->rxqueue + pos); pos += 4; |
451 "YCHT Service: 0x%02x Version: 0x%02x Status: 0x%02x\n", | 451 "YCHT Service: 0x%02x Version: 0x%02x Status: 0x%02x\n", |
452 service, version, status); | 452 service, version, status); |
453 ycht_packet_dump(ycht->rxqueue, YCHT_HEADER_LEN + pktlen); | 453 ycht_packet_dump(ycht->rxqueue, YCHT_HEADER_LEN + pktlen); |
454 | 454 |
455 pkt = ycht_packet_new(version, service, status); | 455 pkt = ycht_packet_new(version, service, status); |
456 ycht_packet_read(pkt, ycht->rxqueue + pos, pktlen); | 456 ycht_packet_read(pkt, (char *)ycht->rxqueue + pos, pktlen); |
457 | 457 |
458 ycht->rxlen -= YCHT_HEADER_LEN + pktlen; | 458 ycht->rxlen -= YCHT_HEADER_LEN + pktlen; |
459 if (ycht->rxlen) { | 459 if (ycht->rxlen) { |
460 char *tmp = g_memdup(ycht->rxqueue + YCHT_HEADER_LEN + pktlen, ycht->rxlen); | 460 guchar *tmp = g_memdup(ycht->rxqueue + YCHT_HEADER_LEN + pktlen, ycht->rxlen); |
461 g_free(ycht->rxqueue); | 461 g_free(ycht->rxqueue); |
462 ycht->rxqueue = tmp; | 462 ycht->rxqueue = tmp; |
463 } else { | 463 } else { |
464 g_free(ycht->rxqueue); | 464 g_free(ycht->rxqueue); |
465 ycht->rxqueue = NULL; | 465 ycht->rxqueue = NULL; |