Bugfix: use the command parser to properly extract workspace names

fixes #1377
This commit is contained in:
Michael Stapelberg
2014-10-01 22:50:48 +02:00
parent 7fe55090ec
commit ea2552e852
4 changed files with 90 additions and 49 deletions

View File

@ -44,6 +44,14 @@ struct CommandResult {
bool needs_tree_render;
};
/**
* Parses a string (or word, if as_word is true). Extracted out of
* parse_command so that it can be used in src/workspace.c for interpreting
* workspace commands.
*
*/
char *parse_string(const char **walk, bool as_word);
/**
* Parses and executes the given command. If a caller-allocated yajl_gen is
* passed, a json reply will be generated in the format specified by the ipc