Mercurial > pidgin
comparison libpurple/protocols/mxit/protocol.c @ 31505:67c2d695e8d5
Move the PIN-change option into a separate PluginAction.
author | andrew.victor@mxit.com |
---|---|
date | Mon, 11 Apr 2011 22:16:34 +0000 |
parents | cce18a0ff43a |
children | 2e4ac25df4ba |
comparison
equal
deleted
inserted
replaced
31504:cce18a0ff43a | 31505:67c2d695e8d5 |
---|---|
851 * @param attributes String containing the attribute-name, attribute-type and value (seperated by '\01') | 851 * @param attributes String containing the attribute-name, attribute-type and value (seperated by '\01') |
852 */ | 852 */ |
853 void mxit_send_extprofile_update( struct MXitSession* session, const char* password, unsigned int nr_attrib, const char* attributes ) | 853 void mxit_send_extprofile_update( struct MXitSession* session, const char* password, unsigned int nr_attrib, const char* attributes ) |
854 { | 854 { |
855 char data[CP_MAX_PACKET]; | 855 char data[CP_MAX_PACKET]; |
856 gchar** parts; | 856 gchar** parts = NULL; |
857 int datalen; | 857 int datalen; |
858 unsigned int i; | 858 unsigned int i; |
859 | 859 |
860 parts = g_strsplit( attributes, "\01", 1 + ( nr_attrib * 3 ) ); | 860 if ( attributes ) |
861 parts = g_strsplit( attributes, "\01", 1 + ( nr_attrib * 3 ) ); | |
861 | 862 |
862 /* convert the packet to a byte stream */ | 863 /* convert the packet to a byte stream */ |
863 datalen = snprintf( data, sizeof( data ), | 864 datalen = snprintf( data, sizeof( data ), |
864 "ms=%s%c%i", /* "ms"=password\1nr_attibutes */ | 865 "ms=%s%c%i", /* "ms"=password\1nr_attibutes */ |
865 ( password ) ? password : "", CP_FLD_TERM, nr_attrib | 866 ( password ) ? password : "", CP_FLD_TERM, nr_attrib |