From 6344ab94b231aa56a2ea93fb96e7c8af87f37052 Mon Sep 17 00:00:00 2001 From: Christian Helmuth Date: Wed, 10 Dec 2014 21:06:12 +0100 Subject: [PATCH] run: use predefined name for wsman script "file tempfile" is not available in tcl versions below 8.6, which are still wide spread, for example, in Ubuntu 12.04.5 LTS. Fixes #1328. --- tool/run | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/tool/run b/tool/run index e74c0fba6..ab97b4198 100755 --- a/tool/run +++ b/tool/run @@ -686,16 +686,16 @@ proc amt_reset_soap_eoi { } { # Reset via Intel AMT wsman protocol # proc amt_reset_wsman { } { - file tempfile xml_request ".xml" + set xml_request "amt-reset-wsman.xml" - set fh [open $xml_request "WRONLY"] + set fh [open $xml_request "WRONLY CREAT TRUNC"] puts $fh { 5 + xmlns:wsman="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd"> http://schemas.xmlsoap.org/ws/2004/08/addressing/role/anonymous http://schemas.dmtf.org/wbem/wscim/1/cim-schema/2/CIM_ComputerSystem @@ -711,8 +711,6 @@ proc amt_reset_wsman { } { close $fh exec wsman invoke -a RequestPowerStateChange -J $xml_request "http://schemas.dmtf.org/wbem/wscim/1/cim-schema/2/CIM_PowerManagementService?SystemCreationClassName=\"CIM_ComputerSystem\",SystemName=\"Intel(r) AMT\",CreationClassName=\"CIM_PowerManagementService\",Name=\"Intel(r) AMT Power Management Service\"" --port 16992 -h $::env(AMT_TEST_MACHINE_IP) --username admin -p $::env(AMT_TEST_MACHINE_PWD) -V -v - - file delete $xml_request }