Skip to content

Commit

Permalink
Display headline sender
Browse files Browse the repository at this point in the history
  • Loading branch information
jubalh committed Aug 11, 2023
1 parent a17544d commit 492efc4
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/xmpp/message.c
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,10 @@ _handle_headline(xmpp_stanza_t* const stanza)
if (body) {
char* text = xmpp_stanza_get_text(body);
if (text) {
cons_show("Headline: %s", text);
const char* const stanza_from = xmpp_stanza_get_from(stanza);
if (stanza_from) {
cons_show("Headline from %s: %s", stanza_from, text);
}
xmpp_free(connection_get_ctx(), text);
}
}
Expand Down

0 comments on commit 492efc4

Please sign in to comment.