comparison libpurple/protocols/oscar/family_locate.c @ 19682:4a372246ca1e

Looks like I might have been wrong about the length being only 8 bits. Fixes #2486 I think
author Mark Doliner <mark@kingant.net>
date Sat, 08 Sep 2007 08:21:06 +0000
parents 44b4e8bd759b
children 1728c7414856
comparison
equal deleted inserted replaced
19680:44b4e8bd759b 19682:4a372246ca1e
634 634
635 /* 635 /*
636 * Parse out the Type-Length-Value triples as they're found. 636 * Parse out the Type-Length-Value triples as they're found.
637 */ 637 */
638 for (curtlv = 0; curtlv < tlvcnt; curtlv++) { 638 for (curtlv = 0; curtlv < tlvcnt; curtlv++) {
639 guint16 type; 639 guint16 type, length;
640 guint8 number, length;
641 int endpos; 640 int endpos;
642 641
643 type = byte_stream_get16(bs); 642 type = byte_stream_get16(bs);
644 number = byte_stream_get8(bs); 643 length = byte_stream_get16(bs);
645 length = byte_stream_get8(bs);
646 644
647 endpos = byte_stream_curpos(bs) + MIN(length, byte_stream_empty(bs)); 645 endpos = byte_stream_curpos(bs) + MIN(length, byte_stream_empty(bs));
648 646
649 if (type == 0x0001) { 647 if (type == 0x0001) {
650 /* 648 /*