Changing inappropriate variable name...

This commit is contained in:
Sandrine Avakian 2017-03-20 14:49:28 +01:00
parent 8da97fe4c1
commit b54310bc3e

View file

@ -659,23 +659,23 @@ LinphoneOnlineStatus linphone_friend_get_status(const LinphoneFriend *lf){
const LinphonePresenceModel * linphone_friend_get_presence_model(const LinphoneFriend *lf) {
const LinphonePresenceModel *presence = NULL;
LinphoneFriend* fuckconst = (LinphoneFriend*)lf;
const bctbx_list_t* addrs = linphone_friend_get_addresses(fuckconst);
LinphoneFriend* const_lf = (LinphoneFriend*)lf;
const bctbx_list_t* addrs = linphone_friend_get_addresses(const_lf);
bctbx_list_t* phones = NULL;
bctbx_list_t *it;
for (it = (bctbx_list_t *)addrs; it!= NULL; it = it->next) {
LinphoneAddress *addr = (LinphoneAddress*)it->data;
char *uri = linphone_address_as_string_uri_only(addr);
presence = linphone_friend_get_presence_model_for_uri_or_tel(fuckconst, uri);
presence = linphone_friend_get_presence_model_for_uri_or_tel(const_lf, uri);
ms_free(uri);
if (presence) break;
}
if (presence) return presence;
phones = linphone_friend_get_phone_numbers(fuckconst);
phones = linphone_friend_get_phone_numbers(const_lf);
for (it = phones; it!= NULL; it = it->next) {
presence = linphone_friend_get_presence_model_for_uri_or_tel(fuckconst, it->data);
presence = linphone_friend_get_presence_model_for_uri_or_tel(const_lf, it->data);
if (presence) break;
}
bctbx_list_free(phones);