summaryrefslogtreecommitdiff
path: root/src/plugins/exec
diff options
context:
space:
mode:
authorSebastien Helleu <flashcode@flashtux.org>2014-03-16 10:08:08 +0100
committerSebastien Helleu <flashcode@flashtux.org>2014-03-16 10:08:08 +0100
commit9a51449ee6856fd13b6e827b0f0690aadf8773c9 (patch)
tree56cef072d70f9fab20b49d0a8cb531699b1f5bd7 /src/plugins/exec
parentbd2a6253864bd38d5ab063e864f3968727d3129c (diff)
downloadweechat-9a51449ee6856fd13b6e827b0f0690aadf8773c9.zip
exec: add return code ("rc") in hashtable sent with option "-hsignal"
Diffstat (limited to 'src/plugins/exec')
-rw-r--r--src/plugins/exec/exec.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/plugins/exec/exec.c b/src/plugins/exec/exec.c
index c10f8e7c6..93fc18693 100644
--- a/src/plugins/exec/exec.c
+++ b/src/plugins/exec/exec.c
@@ -397,6 +397,8 @@ exec_end_command (struct t_exec_cmd *exec_cmd, int return_code)
weechat_hashtable_set (hashtable, "err", output);
if (output)
free (output);
+ snprintf (str_number, sizeof (str_number), "%d", return_code);
+ weechat_hashtable_set (hashtable, "rc", str_number);
weechat_hook_hsignal_send (exec_cmd->hsignal, hashtable);
weechat_hashtable_free (hashtable);
}