From c00bf5d692d89a22357f04ba40ee8a9ed4d79798 Mon Sep 17 00:00:00 2001 From: sawanoboly Date: Tue, 25 Jun 2019 12:29:13 +0900 Subject: add comment Signed-off-by: sawanoboly --- lib/chef/knife/bootstrap/train_connector.rb | 3 +++ 1 file changed, 3 insertions(+) (limited to 'lib') diff --git a/lib/chef/knife/bootstrap/train_connector.rb b/lib/chef/knife/bootstrap/train_connector.rb index 56b644d25d..da5db65de0 100644 --- a/lib/chef/knife/bootstrap/train_connector.rb +++ b/lib/chef/knife/bootstrap/train_connector.rb @@ -117,6 +117,9 @@ class Chef cmd = windows? ? MKTEMP_WIN_COMMAND : MKTEMP_NIX_COMMAND @tmpdir ||= begin res = run_command!(cmd) + # Since pty is enabled in the connection, stderr to be merged into stdout. + # So, there are cases where unnecessary multi-line output + # is included before the result of mktemp. dir = res.stdout.split.last unless windows? # Ensure that dir has the correct owner. We are possibly -- cgit v1.2.1