mirror of
https://github.com/profanity-im/profanity.git
synced 2025-02-02 15:08:15 -05:00
message: fix possible segfault in _handle_muc_user
This commit is contained in:
parent
e656bdb83c
commit
f21a99eaf8
@ -877,6 +877,10 @@ _handle_muc_user(xmpp_stanza_t* const stanza)
|
|||||||
xmpp_stanza_t* xns_muc_user = xmpp_stanza_get_child_by_ns(stanza, STANZA_NS_MUC_USER);
|
xmpp_stanza_t* xns_muc_user = xmpp_stanza_get_child_by_ns(stanza, STANZA_NS_MUC_USER);
|
||||||
const char* room = xmpp_stanza_get_from(stanza);
|
const char* room = xmpp_stanza_get_from(stanza);
|
||||||
|
|
||||||
|
if (!xns_muc_user) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
if (!room) {
|
if (!room) {
|
||||||
log_warning("Message received with no from attribute, ignoring");
|
log_warning("Message received with no from attribute, ignoring");
|
||||||
return;
|
return;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user