git: 39dce0e63898 - main - net-im/dino: fix crash on call

From: Ashish SHUKLA <ashish_at_FreeBSD.org>
Date: Sun, 21 Aug 2022 16:55:52 UTC
The branch main has been updated by ashish:

URL: https://cgit.FreeBSD.org/ports/commit/?id=39dce0e63898092d93f1db6ee4850bef90673b76

commit 39dce0e63898092d93f1db6ee4850bef90673b76
Author:     Rozhuk Ivan <rozhuk.im@gmail.com>
AuthorDate: 2022-08-15 09:13:55 +0000
Commit:     Ashish SHUKLA <ashish@FreeBSD.org>
CommitDate: 2022-08-21 16:54:58 +0000

    net-im/dino: fix crash on call
    
    PR:             265850
---
 net-im/dino/Makefile                                       |  2 +-
 .../files/patch-libdino_src_service_call__peer__state.vala | 14 ++++++++++++++
 2 files changed, 15 insertions(+), 1 deletion(-)

diff --git a/net-im/dino/Makefile b/net-im/dino/Makefile
index 9b714f8fa095..52bbca287a6b 100644
--- a/net-im/dino/Makefile
+++ b/net-im/dino/Makefile
@@ -1,7 +1,7 @@
 PORTNAME=		dino
 DISTVERSIONPREFIX=	v
 DISTVERSION=		0.3.0
-PORTREVISION=		4
+PORTREVISION=		5
 CATEGORIES=		net-im
 
 MAINTAINER=		ashish@FreeBSD.org
diff --git a/net-im/dino/files/patch-libdino_src_service_call__peer__state.vala b/net-im/dino/files/patch-libdino_src_service_call__peer__state.vala
new file mode 100644
index 000000000000..f07a18f02c82
--- /dev/null
+++ b/net-im/dino/files/patch-libdino_src_service_call__peer__state.vala
@@ -0,0 +1,14 @@
+--- libdino/src/service/call_peer_state.vala	2022-02-13 00:18:06.000000000 +0300
++++ libdino/src/service/call_peer_state.vala	2022-08-15 12:07:56.735765000 +0300
+@@ -45,7 +45,10 @@
+         this.stream_interactor = stream_interactor;
+         this.calls = stream_interactor.get_module(Calls.IDENTITY);
+ 
+-        var session_info_type = stream_interactor.module_manager.get_module(call.account, Xep.JingleRtp.Module.IDENTITY).session_info_type;
++        Xep.JingleRtp.Module jinglertp_module = stream_interactor.module_manager.get_module(call.account, Xep.JingleRtp.Module.IDENTITY);
++        if (jinglertp_module == null) return;
++
++        var session_info_type = jinglertp_module.session_info_type;
+         session_info_type.mute_update_received.connect((session,mute, name) => {
+             if (this.sid != session.sid) return;
+