summaryrefslogtreecommitdiffstats
path: root/src/shell.h
diff options
context:
space:
mode:
authorMatthias Schiffer <mschiffer@universe-factory.net>2014-04-11 18:56:47 +0200
committerMatthias Schiffer <mschiffer@universe-factory.net>2014-04-11 18:56:47 +0200
commit7cac6770e0b380d6e5f37b9fad71c9f7f15952ba (patch)
tree8d2c695f27361aa8b3b6d91038f4c78182f64a16 /src/shell.h
parenta45a313422efa33f261cb1b53a08646a6b3ab947 (diff)
downloadfastd-7cac6770e0b380d6e5f37b9fad71c9f7f15952ba.tar
fastd-7cac6770e0b380d6e5f37b9fad71c9f7f15952ba.zip
Add support for async commands
Diffstat (limited to 'src/shell.h')
-rw-r--r--src/shell.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/shell.h b/src/shell.h
index 18ceb2a..e6c3618 100644
--- a/src/shell.h
+++ b/src/shell.h
@@ -35,6 +35,7 @@
struct fastd_shell_command {
char *command;
char *dir;
+ bool sync;
};
static inline void fastd_shell_command_unset(fastd_shell_command_t *command) {
@@ -45,11 +46,12 @@ static inline void fastd_shell_command_unset(fastd_shell_command_t *command) {
command->dir = NULL;
}
-static inline void fastd_shell_command_set(fastd_shell_command_t *command, const char *val) {
+static inline void fastd_shell_command_set(fastd_shell_command_t *command, const char *val, bool sync) {
fastd_shell_command_unset(command);
command->command = strdup(val);
command->dir = get_current_dir_name();
+ command->sync = sync;
}
static inline bool fastd_shell_command_isset(const fastd_shell_command_t *command) {