about summary refs log tree commit diff stats
path: root/src/event
diff options
context:
space:
mode:
authorJohn Hernandez <129467592+H3rnand3zzz@users.noreply.github.com>2023-03-31 02:48:20 +0200
committerJohn Hernandez <129467592+H3rnand3zzz@users.noreply.github.com>2023-03-31 12:30:51 +0200
commit99c9f150f68ae7087e51f217ebd62010fcf07c16 (patch)
treef7873374335b37ecb46d6b69cc11f230deed7829 /src/event
parent2093fe417f6a1d7f8741613a83ed81e18ae272c9 (diff)
downloadprofani-tty-99c9f150f68ae7087e51f217ebd62010fcf07c16.tar.gz
Fix PGP
Fix of PGP and potentially other encryption methods by calling correct function that would initiate them in case if someone writes.
Diffstat (limited to 'src/event')
-rw-r--r--src/event/server_events.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/event/server_events.c b/src/event/server_events.c
index b4845b11..eb3e96e7 100644
--- a/src/event/server_events.c
+++ b/src/event/server_events.c
@@ -645,8 +645,8 @@ sv_ev_incoming_message(ProfMessage* message)
     chatwin = wins_get_chat(looking_for_jid);
 
     if (!chatwin) {
-        ProfWin* window = wins_new_chat(looking_for_jid);
-        chatwin = (ProfChatWin*)window;
+        chatwin = chatwin_new(looking_for_jid);
+        ProfWin* window = (ProfWin*)chatwin;
         new_win = TRUE;
 
         if (prefs_get_boolean(PREF_MAM)) {
@@ -689,8 +689,7 @@ sv_ev_incoming_carbon(ProfMessage* message)
     gboolean new_win = FALSE;
     ProfChatWin* chatwin = wins_get_chat(message->from_jid->barejid);
     if (!chatwin) {
-        ProfWin* window = wins_new_chat(message->from_jid->barejid);
-        chatwin = (ProfChatWin*)window;
+        chatwin = chatwin_new(message->from_jid->barejid);
         new_win = TRUE;
 
 #ifdef HAVE_OMEMO