diff options
author | Sergey Poznyakoff <gray@gnu.org.ua> | 2016-10-13 09:51:25 +0300 |
---|---|---|
committer | Sergey Poznyakoff <gray@gnu.org.ua> | 2016-10-13 09:51:25 +0300 |
commit | d777de47b14d6919400f3359f9edad97096b9e11 (patch) | |
tree | 03b17e0db875cd4f5d28a0aef1178442b354279e | |
parent | 370c4bab61d8d944b4f1f304ed00d6ceb6047b72 (diff) | |
download | rex-d777de47b14d6919400f3359f9edad97096b9e11.tar.gz rex-d777de47b14d6919400f3359f9edad97096b9e11.tar.bz2 |
Bugfix
Prefix unrecognized messages obtained in the INIT state with "ssh HOSTNAME".
Fix behavior of --ignore-hosts with legacy configuration.
-rwxr-xr-x | rex | 15 |
1 files changed, 8 insertions, 7 deletions
@@ -2271,7 +2271,7 @@ proc runcmd {hosts command} { switch -- [job get $batch $sid state] { {INIT} { set text [regsub -all {[\r\n]} $expect_out(0,string) {}] - terror -nosave "[job id $batch $sid]: $text" + terror -nosave "ssh [job id $batch $sid]: $text" } {COMMAND} - {SUDO} { @@ -2686,12 +2686,13 @@ namespace eval ::config { terror -nosave "warning: please change this to \"[apply $update_hint($var) [valueof $var]]\"" } if {[info exists config($var)]} { - if {$var == "hosts" && - ![info exists config(option,ignore-hosts)]} { - set hosts [valueof hosts] - lappend hosts {*}$config(hosts) - set config(hosts) $hosts - debug 3 "config(hosts) = $config(hosts)" + if {$var == "hosts"} { + if {![info exists config(option,ignore-hosts)]} { + set hosts [valueof hosts] + lappend hosts {*}$config(hosts) + set config(hosts) $hosts + debug 3 "config(hosts) = $config(hosts)" + } } } else { set config($var) [valueof $var] |