Mercurial > pidgin.yaz
diff libpurple/protocols/msn/tlv.h @ 32016:bd59044a9100
The type and length of the TLV are only bytes, so fix the function
declarations and definitions.
author | Elliott Sales de Andrade <qulogic@pidgin.im> |
---|---|
date | Sat, 07 May 2011 07:14:48 +0000 |
parents | 506b77a27a53 |
children | c714ccbcdf00 |
line wrap: on
line diff
--- a/libpurple/protocols/msn/tlv.h Fri May 06 17:20:19 2011 +0000 +++ b/libpurple/protocols/msn/tlv.h Sat May 07 07:14:48 2011 +0000 @@ -38,12 +38,12 @@ /* TLV handling functions */ char *msn_tlv_getvalue_as_string(msn_tlv_t *tlv); -msn_tlv_t *msn_tlv_gettlv(GSList *list, const guint16 type, const int nth); -int msn_tlv_getlength(GSList *list, const guint16 type, const int nth); -char *msn_tlv_getstr(GSList *list, const guint16 type, const int nth); -guint8 msn_tlv_get8(GSList *list, const guint16 type, const int nth); -guint16 msn_tlv_get16(GSList *list, const guint16 type, const int nth); -guint32 msn_tlv_get32(GSList *list, const guint16 type, const int nth); +msn_tlv_t *msn_tlv_gettlv(GSList *list, const guint8 type, const int nth); +int msn_tlv_getlength(GSList *list, const guint8 type, const int nth); +char *msn_tlv_getstr(GSList *list, const guint8 type, const int nth); +guint8 msn_tlv_get8(GSList *list, const guint8 type, const int nth); +guint16 msn_tlv_get16(GSList *list, const guint8 type, const int nth); +guint32 msn_tlv_get32(GSList *list, const guint8 type, const int nth); /* TLV list handling functions */ GSList *msn_tlvlist_read(const char *bs, size_t bs_len); @@ -55,21 +55,21 @@ char *msn_tlvlist_write(GSList *list, size_t *out_len); void msn_tlvlist_free(GSList *list); -int msn_tlvlist_add_raw(GSList **list, const guint16 type, const guint16 length, const char *value); -int msn_tlvlist_add_empty(GSList **list, const guint16 type); -int msn_tlvlist_add_8(GSList **list, const guint16 type, const guint8 value); -int msn_tlvlist_add_16(GSList **list, const guint16 type, const guint16 value); -int msn_tlvlist_add_32(GSList **list, const guint16 type, const guint32 value); -int msn_tlvlist_add_str(GSList **list, const guint16 type, const char *value); +int msn_tlvlist_add_raw(GSList **list, const guint8 type, const guint8 length, const char *value); +int msn_tlvlist_add_empty(GSList **list, const guint8 type); +int msn_tlvlist_add_8(GSList **list, const guint8 type, const guint8 value); +int msn_tlvlist_add_16(GSList **list, const guint8 type, const guint16 value); +int msn_tlvlist_add_32(GSList **list, const guint8 type, const guint32 value); +int msn_tlvlist_add_str(GSList **list, const guint8 type, const char *value); -int msn_tlvlist_replace_raw(GSList **list, const guint16 type, const guint16 lenth, const char *value); -int msn_tlvlist_replace_str(GSList **list, const guint16 type, const char *str); -int msn_tlvlist_replace_empty(GSList **list, const guint16 type); -int msn_tlvlist_replace_8(GSList **list, const guint16 type, const guint8 value); -int msn_tlvlist_replace_16(GSList **list, const guint16 type, const guint16 value); -int msn_tlvlist_replace_32(GSList **list, const guint16 type, const guint32 value); +int msn_tlvlist_replace_raw(GSList **list, const guint8 type, const guint8 lenth, const char *value); +int msn_tlvlist_replace_str(GSList **list, const guint8 type, const char *str); +int msn_tlvlist_replace_empty(GSList **list, const guint8 type); +int msn_tlvlist_replace_8(GSList **list, const guint8 type, const guint8 value); +int msn_tlvlist_replace_16(GSList **list, const guint8 type, const guint16 value); +int msn_tlvlist_replace_32(GSList **list, const guint8 type, const guint32 value); -void msn_tlvlist_remove(GSList **list, const guint16 type); +void msn_tlvlist_remove(GSList **list, const guint8 type); #endif /* MSN_TLV_H */