summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authordequis <dx@dxzone.com.ar>2018-03-28 23:06:47 -0300
committerdequis <dx@dxzone.com.ar>2018-03-28 23:06:47 -0300
commitdd7dc7ca7d0b04ae2d522a209845c453bfd9aab5 (patch)
tree3f1479a4d4f17a54d6287b1bdd4dc82a828b4488
parentb52cf1015eaa4d759c9377df35a56988655dce89 (diff)
downloadirssi-dd7dc7ca7d0b04ae2d522a209845c453bfd9aab5.zip
otr: fix missing 'target' param in 'message private' signal
Fixes warnings like these on '/msg yourself' -!- Irssi: critical privmsg_get_query: assertion 'nick != NULL' failed -!- Irssi: critical query_find: assertion 'nick != NULL' failed
-rw-r--r--src/otr/module.c6
-rw-r--r--src/otr/module.h2
2 files changed, 4 insertions, 4 deletions
diff --git a/src/otr/module.c b/src/otr/module.c
index 0d83629f..f561b91c 100644
--- a/src/otr/module.c
+++ b/src/otr/module.c
@@ -79,7 +79,7 @@ static void sig_server_sendmsg(SERVER_REC *server, const char *target,
/*
* Pipes all incoming private messages through OTR
*/
-void sig_message_private(SERVER_REC *server, const char *msg, const char *nick, const char *address)
+void sig_message_private(SERVER_REC *server, const char *msg, const char *nick, const char *address, const char *target)
{
char *new_msg = NULL;
@@ -91,7 +91,7 @@ void sig_message_private(SERVER_REC *server, const char *msg, const char *nick,
if (new_msg == NULL) {
/* This message was not OTR */
- signal_continue(4, server, msg, nick, address);
+ signal_continue(5, server, msg, nick, address, target);
} else {
/*
* Check for /me IRC marker and if so, handle it so the user does not
@@ -103,7 +103,7 @@ void sig_message_private(SERVER_REC *server, const char *msg, const char *nick,
signal_emit("message irc action", 5, server, new_msg + OTR_IRC_MARKER_ME_LEN, nick, address, nick);
} else {
/* OTR received message */
- signal_continue(4, server, new_msg, nick, address);
+ signal_continue(5, server, new_msg, nick, address, target);
}
}
diff --git a/src/otr/module.h b/src/otr/module.h
index fdfc77bd..513ee03b 100644
--- a/src/otr/module.h
+++ b/src/otr/module.h
@@ -24,6 +24,6 @@
#include "common.h"
#include "servers.h"
-void sig_message_private(SERVER_REC *server, const char *msg, const char *nick, const char *address);
+void sig_message_private(SERVER_REC *server, const char *msg, const char *nick, const char *address, const char *target);
#endif /* IRSSI_OTR_MODULE */