Check account creator native ptr before unref in Java wrapper

This commit is contained in:
Sylvain Berfini 2018-04-26 10:18:13 +02:00 committed by Simon Morlat
parent 5bcfd768a4
commit 4e6c089046

View file

@ -35,7 +35,7 @@ public class LinphoneAccountCreatorImpl implements LinphoneAccountCreator {
private native void unref(long ptr);
protected void finalize() {
unref(nativePtr);
if (nativePtr!=0) unref(nativePtr);
}
private native void setListener(long ptr, LinphoneAccountCreatorListener listener);