account_creator.c: update to latest xmlrpc api

This commit is contained in:
Gautier Pelloux-Prayer 2016-08-29 11:24:22 +02:00
parent 76ae2dc43a
commit ca03c42f4a

View file

@ -727,7 +727,12 @@ static void _recover_phone_account_cb(LinphoneXmlRpcRequest *request) {
LinphoneAccountCreatorStatus status = LinphoneAccountCreatorReqFailed;
const char* resp = linphone_xml_rpc_request_get_string_response(request);
if (linphone_xml_rpc_request_get_status(request) == LinphoneXmlRpcStatusOk) {
status = (strstr(resp, "ERROR_") == resp) ? LinphoneAccountCreatorReqFailed : LinphoneAccountCreatorOK;
if (strstr(resp, "ERROR_") == resp) {
status = LinphoneAccountCreatorReqFailed;
} else {
status = LinphoneAccountCreatorOK;
set_string(&creator->username, resp, FALSE);
}
}
creator->callbacks->recover_phone_account(creator, status, resp);
}