summaryrefslogtreecommitdiff
path: root/src/plugins/scripts/python
diff options
context:
space:
mode:
Diffstat (limited to 'src/plugins/scripts/python')
-rw-r--r--src/plugins/scripts/python/weechat-python.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/plugins/scripts/python/weechat-python.c b/src/plugins/scripts/python/weechat-python.c
index 381fabf26..297e27ce9 100644
--- a/src/plugins/scripts/python/weechat-python.c
+++ b/src/plugins/scripts/python/weechat-python.c
@@ -257,7 +257,10 @@ weechat_python_event_handler (t_weechat_plugin *plugin,
{
r = (int *) weechat_python_exec (plugin, (t_plugin_script *)handler_pointer,
SCRIPT_EXEC_INT,
- handler_args, argv[0], NULL, NULL);
+ handler_args,
+ argv[0],
+ (argc >= 2) ? argv[1] : NULL,
+ (argc >= 3) ? argv[2] : NULL);
if (r == NULL)
ret = PLUGIN_RC_KO;
else