From 4689fcb53c3bd55411b2ada02350e6442d82fe25 Mon Sep 17 00:00:00 2001 From: eerielili Date: Sun, 10 Dec 2023 12:28:22 +0000 Subject: [PATCH] Fix segfault opening conversation details when no XEP-0191 support (#1513) fixes #1508 --- xmpp-vala/src/module/xep/0191_blocking_command.vala | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/xmpp-vala/src/module/xep/0191_blocking_command.vala b/xmpp-vala/src/module/xep/0191_blocking_command.vala index 987f538a..9e5ede78 100644 --- a/xmpp-vala/src/module/xep/0191_blocking_command.vala +++ b/xmpp-vala/src/module/xep/0191_blocking_command.vala @@ -12,7 +12,11 @@ public class Module : XmppStreamModule, Iq.Handler { public signal void unblock_all_received(XmppStream stream); public bool is_blocked(XmppStream stream, string jid) { - return stream.get_flag(Flag.IDENTITY).blocklist.contains(jid); + if (is_supported(stream)) { + return stream.get_flag(Flag.IDENTITY).blocklist.contains(jid); + } else { + return false; + } } public bool block(XmppStream stream, string[] jids) {