From 7719eb7609ef7f47960474838fc63b84e7ca2fd3 Mon Sep 17 00:00:00 2001 From: Donat Zenichev Date: Thu, 10 Apr 2025 16:17:58 +0200 Subject: [PATCH] MT#62253 log: AmSession: log only when dlg is added already Otherwise we can end up with: Program terminated with signal SIGSEGV, Segmentation fault. 104 ./core/AmSession.cpp: No such file or directory. [Current thread is 1 (Thread 0x7fc7dd677e40 (LWP 176249))] Change-Id: Ia61de0caa9b1764839c740e62bc3f463da4ed4dc --- core/AmSession.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/core/AmSession.cpp b/core/AmSession.cpp index fb2a15c9..d61bee51 100644 --- a/core/AmSession.cpp +++ b/core/AmSession.cpp @@ -88,9 +88,10 @@ AmSession::AmSession(AmSipDialog* p_dlg) , _pid(this) #endif { - ILOG_DLG(L_DBG, "dlg = %p",dlg); if(!dlg) dlg = new AmSipDialog(this); else dlg->setEventhandler(this); + + ILOG_DLG(L_DBG, "dlg = %p",dlg); } AmSession::~AmSession()