From 2b80410aaf124e29745f70a7d807474b88c376dc Mon Sep 17 00:00:00 2001 From: Jan Schneider Date: Tue, 24 Oct 2017 08:20:28 +0200 Subject: [PATCH] redirect unzip stderr output to /dev/null otherwise tcl exec command will throw an error --- addon/lib/rmupdate.tcl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/addon/lib/rmupdate.tcl b/addon/lib/rmupdate.tcl index 560fff8..767ff67 100644 --- a/addon/lib/rmupdate.tcl +++ b/addon/lib/rmupdate.tcl @@ -463,7 +463,7 @@ proc ::rmupdate::download_firmware {version} { write_log "Download completed." write_log "Extracting firmware ${archive_file}." - set data [exec /usr/bin/unzip -ql "${archive_file}"] + set data [exec /usr/bin/unzip -ql "${archive_file}" 2>/dev/null] set img_file "" foreach d [split $data "\n"] { regexp {\s+(\S+\.img)\s*$} $d match img_file @@ -474,7 +474,7 @@ proc ::rmupdate::download_firmware {version} { if { $img_file == "" } { error "Failed to extract image from archive." } - exec /usr/bin/unzip "${archive_file}" "${img_file}" -o -d "${img_dir}" + exec /usr/bin/unzip "${archive_file}" "${img_file}" -o -d "${img_dir}" 2>/dev/null set img_file "${img_dir}/${img_file}" puts "${img_file} ${image_file}" if {$img_file != $image_file} {