summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--cli/src/input.c2
-rw-r--r--tests/bugs/bug-1047378.t12
2 files changed, 13 insertions, 1 deletions
diff --git a/cli/src/input.c b/cli/src/input.c
index a8ea46c6d..26f337c3c 100644
--- a/cli/src/input.c
+++ b/cli/src/input.c
@@ -87,7 +87,7 @@ cli_input_init (struct cli_state *state)
cli_rl_enable (state);
} else {
state->prompt = "";
- state->mode = GLUSTER_MODE_SCRIPT | GLUSTER_MODE_ERR_FATAL;
+ state->mode |= GLUSTER_MODE_SCRIPT | GLUSTER_MODE_ERR_FATAL;
}
if (!state->rl_enabled)
diff --git a/tests/bugs/bug-1047378.t b/tests/bugs/bug-1047378.t
new file mode 100644
index 000000000..b441ee9b1
--- /dev/null
+++ b/tests/bugs/bug-1047378.t
@@ -0,0 +1,12 @@
+#!/bin/bash
+
+. $(dirname $0)/../include.rc
+
+cleanup;
+
+TEST glusterd
+TEST pidof glusterd
+
+TEST "echo volume list | $CLI --xml | xmllint --format -"
+
+cleanup