summaryrefslogtreecommitdiffhomepage
path: root/proto-shell.c
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2011-09-10 18:37:52 +0200
committerFelix Fietkau <nbd@openwrt.org>2011-09-10 18:37:52 +0200
commit838526ce765052bc1fe6c34cee3811027f519a14 (patch)
tree002fefd876db5df8282f1888c38d2f775982eebd /proto-shell.c
parentc601d036d6e9efce0c31eecd0fc66a716f41f2a3 (diff)
move the DUMP_SUFFIX define to the right place
Diffstat (limited to 'proto-shell.c')
-rw-r--r--proto-shell.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/proto-shell.c b/proto-shell.c
index 84d1c9c..8d99c74 100644
--- a/proto-shell.c
+++ b/proto-shell.c
@@ -29,8 +29,6 @@ struct proto_shell_state {
struct blob_attr *config;
};
-#define DUMP_SUFFIX " '' dump"
-
static int run_script(const char **argv)
{
int pid, ret;
@@ -231,6 +229,8 @@ static void proto_shell_add_script(const char *name)
FILE *f;
int buflen, len;
+#define DUMP_SUFFIX " '' dump"
+
cmd = alloca(strlen(name) + 1 + sizeof(DUMP_SUFFIX));
sprintf(cmd, "%s" DUMP_SUFFIX, name);