Added Redirect Mode account setting that tells if call redirect requests

(3xx responses) can be followed automatically or if confirmation
  needs to be asked
This commit is contained in:
Juha Heinanen
2023-07-02 15:20:06 +03:00
parent 29708ea58f
commit 2394f3fba1
9 changed files with 125 additions and 3 deletions

View File

@ -184,6 +184,9 @@ static void ua_event_handler(
case UA_EVENT_CALL_ANSWERED:
len = re_snprintf(event_buf, sizeof event_buf, "call answered");
break;
case UA_EVENT_CALL_REDIRECT:
len = re_snprintf(event_buf, sizeof event_buf, "call redirect,%s", prm + 4);
break;
case UA_EVENT_CALL_LOCAL_SDP:
if (strcmp(prm, "offer") == 0)
return;
@ -958,6 +961,18 @@ JNIEXPORT jint JNICALL Java_com_tutpro_baresip_Api_account_1set_1answermode(
return account_set_answermode((struct account *)acc, mode);
}
JNIEXPORT jboolean JNICALL Java_com_tutpro_baresip_Api_account_1sip_1autoredirect(
JNIEnv *env, jobject thiz, jlong acc)
{
return account_sip_autoredirect((struct account *)acc);
}
JNIEXPORT void JNICALL Java_com_tutpro_baresip_Api_account_1set_1sip_1autoredirect(
JNIEnv *env, jobject thiz, jlong acc, jboolean allow)
{
return account_set_sip_autoredirect((struct account *)acc, allow);
}
JNIEXPORT jboolean JNICALL Java_com_tutpro_baresip_Api_account_1rtcp_1mux(
JNIEnv *env, jobject thiz, jlong acc)
{