summaryrefslogtreecommitdiff
path: root/src/commands.c
diff options
context:
space:
mode:
authorportix <none@none>2013-02-01 01:14:41 +0100
committerportix <none@none>2013-02-01 01:14:41 +0100
commit3182ab0b97f621f4e4fd5a4f56e8d7400a995ccd (patch)
treec8891b1de5f588331056a321d18fa95d67f1aa7c /src/commands.c
parent876f8dbffea7286078d3548af49031a8c4e20d8a (diff)
downloaddwb-3182ab0b97f621f4e4fd5a4f56e8d7400a995ccd.zip
Escape all characters that must be escaped in util_create_json, additional argument-parameter in commands_simple_command
Diffstat (limited to 'src/commands.c')
-rw-r--r--src/commands.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/commands.c b/src/commands.c
index 4b885fd3..3d052168 100644
--- a/src/commands.c
+++ b/src/commands.c
@@ -44,7 +44,7 @@ modulo(int x, int y) {
/* commands.h {{{*/
/* commands_simple_command(keyMap *km) {{{*/
DwbStatus
-commands_simple_command(KeyMap *km)
+commands_simple_command(KeyMap *km, const char *argument)
{
int ret;
gboolean (*func)(void *, void *) = km->map->func;
@@ -60,7 +60,7 @@ commands_simple_command(KeyMap *km)
{
char *json = util_create_json(3,
CHAR, "command", km->map->n.first,
- CHAR, "argument", arg->p,
+ CHAR, "argument", argument,
INTEGER, "nummod", dwb.state.nummod);
ScriptSignal sig = { NULL, SCRIPTS_SIG_META(json, EXECUTE_COMMAND, 0) } ;