From c0b32a738f238c0d87e83ec6eda3d6e0de6bbe51 Mon Sep 17 00:00:00 2001 From: Erwan Croze <erwan.croze@belledonne-communications.com> Date: Wed, 23 Nov 2016 11:53:13 +0100 Subject: [PATCH] Fix crash which happened sometime on remove of proxy config --- java/impl/org/linphone/core/LinphoneCoreImpl.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/java/impl/org/linphone/core/LinphoneCoreImpl.java b/java/impl/org/linphone/core/LinphoneCoreImpl.java index 61a44582e7..75bfd53955 100644 --- a/java/impl/org/linphone/core/LinphoneCoreImpl.java +++ b/java/impl/org/linphone/core/LinphoneCoreImpl.java @@ -278,7 +278,9 @@ class LinphoneCoreImpl implements LinphoneCore { } public synchronized void removeProxyConfig(LinphoneProxyConfig proxyCfg) { isValid(); - removeProxyConfig(nativePtr, ((LinphoneProxyConfigImpl) proxyCfg).nativePtr); + if (proxyCfg != null) { + removeProxyConfig(nativePtr, ((LinphoneProxyConfigImpl) proxyCfg).nativePtr); + } } public synchronized void clearAuthInfos() { isValid(); -- GitLab