mirror of
https://gitlab.linphone.org/BC/public/linphone-iphone.git
synced 2026-05-07 05:53:06 +00:00
Merge branch 'master' of git.savannah.nongnu.org:/srv/git/linphone
This commit is contained in:
commit
f0e39cf98b
5 changed files with 32 additions and 1 deletions
|
|
@ -4328,3 +4328,22 @@ void linphone_core_set_zrtp_secrets_file(LinphoneCore *lc, const char* file){
|
|||
}
|
||||
lc->zrtp_secrets_cache=file ? ms_strdup(file) : NULL;
|
||||
}
|
||||
|
||||
// if (stringUri.equals(call.getRemoteAddress().asStringUriOnly())) {
|
||||
const LinphoneCall* linphone_core_find_call_from_uri(LinphoneCore *lc, const char *uri) {
|
||||
if (uri == NULL) return NULL;
|
||||
MSList *calls=lc->calls;
|
||||
while(calls) {
|
||||
const LinphoneCall *c=(LinphoneCall*)calls->data;
|
||||
calls=calls->next;
|
||||
const LinphoneAddress *address = linphone_call_get_remote_address(c);
|
||||
char *current_uri=linphone_address_as_string_uri_only(address);
|
||||
if (strcmp(uri,current_uri)==0) {
|
||||
ms_free(current_uri);
|
||||
return c;
|
||||
} else {
|
||||
ms_free(current_uri);
|
||||
}
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1017,6 +1017,8 @@ bool_t linphone_call_are_all_streams_encrypted(LinphoneCall *call);
|
|||
const char* linphone_call_get_authentication_token(LinphoneCall *call);
|
||||
bool_t linphone_call_get_authentication_token_verified(LinphoneCall *call);
|
||||
|
||||
const LinphoneCall* linphone_core_find_call_from_uri(LinphoneCore *lc, const char *uri);
|
||||
|
||||
int linphone_core_add_to_conference(LinphoneCore *lc, LinphoneCall *call);
|
||||
int linphone_core_add_all_to_conference(LinphoneCore *lc);
|
||||
int linphone_core_remove_from_conference(LinphoneCore *lc, LinphoneCall *call);
|
||||
|
|
|
|||
|
|
@ -1420,6 +1420,14 @@ extern "C" void Java_org_linphone_core_LinphoneCoreImpl_setZrtpSecretsCache(JNIE
|
|||
}
|
||||
}
|
||||
|
||||
extern "C" jlong Java_org_linphone_core_LinphoneCoreImpl_findCallFromUri(JNIEnv *env,jobject thiz,jlong pCore, jstring jUri) {
|
||||
const char* cUri=env->GetStringUTFChars(jUri, NULL);
|
||||
const LinphoneCall *call=linphone_core_find_call_from_uri((LinphoneCore *) pCore,cUri);
|
||||
env->ReleaseStringUTFChars(jUri, cUri);
|
||||
return (jlong) call;
|
||||
}
|
||||
|
||||
|
||||
extern "C" jint Java_org_linphone_core_LinphoneCoreImpl_setVideoDevice(JNIEnv *env,jobject thiz,jlong pCore,jint id) {
|
||||
LinphoneCore* lc = (LinphoneCore *) pCore;
|
||||
const char** devices = linphone_core_get_video_devices(lc);
|
||||
|
|
|
|||
|
|
@ -761,7 +761,7 @@ int sal_call_refer_with_replaces(SalOp *h, SalOp *other_call_h){
|
|||
}
|
||||
|
||||
SalOp *sal_call_get_replaces(SalOp *h){
|
||||
if (h->replaces!=NULL){
|
||||
if (h!=NULL && h->replaces!=NULL){
|
||||
int cid;
|
||||
eXosip_lock();
|
||||
cid=eXosip_call_find_by_replaces(h->replaces);
|
||||
|
|
|
|||
|
|
@ -619,4 +619,6 @@ public interface LinphoneCore {
|
|||
|
||||
void transferCall(LinphoneCall call, String referTo);
|
||||
void transferCallToAnother(LinphoneCall callToTransfer, LinphoneCall destination);
|
||||
|
||||
LinphoneCall findCallFromUri(String uri);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue