summaryrefslogtreecommitdiff
path: root/etc/bash_completion.d
diff options
context:
space:
mode:
authorStephen Hemminger <stephen.hemminger@vyatta.com>2008-03-14 09:03:48 -0700
committerStephen Hemminger <stephen.hemminger@vyatta.com>2008-03-14 09:03:48 -0700
commit6911e754d8a5699498dee311a3138298cb07ebaf (patch)
tree0a26827b241b37dd1b5866fbce0a71fdaf12d120 /etc/bash_completion.d
parent67ebf64095378d5108d01a58f3aec7433258eb55 (diff)
downloadvyatta-op-6911e754d8a5699498dee311a3138298cb07ebaf.tar.gz
vyatta-op-6911e754d8a5699498dee311a3138298cb07ebaf.zip
Better fix for interrupted shell commands problem.
By doing pipeline as: eval "( $cmd ) | $PAGER" this avoids the problem that if top level pipeline is interrupted the shell puts the command into stopped mode. Since job control commands are not available in operational mode, the job would stay stuck.
Diffstat (limited to 'etc/bash_completion.d')
-rw-r--r--etc/bash_completion.d/10vyatta-op4
1 files changed, 2 insertions, 2 deletions
diff --git a/etc/bash_completion.d/10vyatta-op b/etc/bash_completion.d/10vyatta-op
index 538d5c0..ebff99f 100644
--- a/etc/bash_completion.d/10vyatta-op
+++ b/etc/bash_completion.d/10vyatta-op
@@ -285,7 +285,7 @@ _vyatta_op_expand ()
_vyatta_op_help "$cur" \
${_vyatta_op_noncompletions[@]} \
${_vyatta_op_completions[@]} \
- | eval ${VYATTA_PAGER:-cat}
+ | ${VYATTA_PAGER:-cat}
COMPREPLY=( "" " " )
_vyatta_op_last_comp=${_vyatta_op_last_comp_init}
else
@@ -319,7 +319,7 @@ _vyatta_op_run ()
local ret=0
if [ -n "$run_cmd" ]; then
if [[ -t 1 && "$1" == "show" ]] ; then
- ( eval "$run_cmd" ) | eval "${VYATTA_PAGER:-cat}"
+ eval "($run_cmd) | ${VYATTA_PAGER:-cat}"
else
eval "$run_cmd"
fi