int i;
ms_message("Outgoing call failed with SRTP (SAVP) enabled - retrying with AVP");
linphone_call_stop_media_streams(call);
- /* clear SRTP local params */
- call->params.media_encryption = LinphoneMediaEncryptionNone;
- for(i=0; i<call->localdesc->nstreams; i++) {
- call->localdesc->streams[i].proto = SalProtoRtpAvp;
- memset(call->localdesc->streams[i].crypto, 0, sizeof(call->localdesc->streams[i].crypto));
+ if (call->state==LinphoneCallOutgoingInit || call->state==LinphoneCallOutgoingProgress){
+ /* clear SRTP local params */
+ call->params.media_encryption = LinphoneMediaEncryptionNone;
+ for(i=0; i<call->localdesc->nstreams; i++) {
+ call->localdesc->streams[i].proto = SalProtoRtpAvp;
+ memset(call->localdesc->streams[i].crypto, 0, sizeof(call->localdesc->streams[i].crypto));
+ }
+ linphone_core_start_invite(lc, call, NULL);
}
- linphone_core_start_invite(lc, call, NULL);
return;
}
- msg=_("No common codecs");
+ msg=_("Incompatible media parameters.");
if (lc->vtable.display_status)
lc->vtable.display_status(lc,msg);
break;