Commit 73445320 authored by Ghislain MARY's avatar Ghislain MARY
Browse files

Fix crash if user pointer of op is null in call failure callback.

parent 7c27d3c9
......@@ -256,7 +256,9 @@ static void call_terminated(SalOp *op, const char *from) {
static void call_failure(SalOp *op) {
std::shared_ptr<LinphonePrivate::CallSession> session = reinterpret_cast<LinphonePrivate::CallSession *>(op->get_user_pointer())->getSharedFromThis();
shared_ptr<LinphonePrivate::CallSession> session;
if (op->get_user_pointer())
session = reinterpret_cast<LinphonePrivate::CallSession *>(op->get_user_pointer())->getSharedFromThis();
if (!session) {
ms_warning("Failure reported on already terminated CallSession");
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment