"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "lib/remote.exp" between
dejagnu-1.6.tar.gz and dejagnu-1.6.1.tar.gz

About: DejaGnu is a framework for testing other programs.

remote.exp  (dejagnu-1.6):remote.exp  (dejagnu-1.6.1)
# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001 # Copyright (C) 1992-2016 Free Software Foundation, Inc.
# 2002, 2003, 2005, 2006, 2007, 2008, 2009, 2010 Free Software Foundation, Inc.
# #
# This file is part of DejaGnu. # This file is part of DejaGnu.
# #
# DejaGnu is free software; you can redistribute it and/or modify it # DejaGnu is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by # under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 3 of the License, or # the Free Software Foundation; either version 3 of the License, or
# (at your option) any later version. # (at your option) any later version.
# #
# DejaGnu is distributed in the hope that it will be useful, but # DejaGnu is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of # WITHOUT ANY WARRANTY; without even the implied warranty of
skipping to change at line 29 skipping to change at line 28
# This file was written by Rob Savoye <rob@welcomehome.org>. # This file was written by Rob Savoye <rob@welcomehome.org>.
# Load various protocol support modules. # Load various protocol support modules.
load_lib "telnet.exp" load_lib "telnet.exp"
load_lib "rlogin.exp" load_lib "rlogin.exp"
load_lib "kermit.exp" load_lib "kermit.exp"
load_lib "tip.exp" load_lib "tip.exp"
load_lib "rsh.exp" load_lib "rsh.exp"
load_lib "ssh.exp"
load_lib "ftp.exp" load_lib "ftp.exp"
# Open a connection to a remote host or target. This requires the target_info # Open a connection to a remote host or target. This requires the target_info
# array be filled in with the proper info to work. # array be filled in with the proper info to work.
# #
# type is either "build", "host", "target", or the name of a board loaded # type is either "build", "host", "target", or the name of a board loaded
# into the board_info array. The default is target if no name is supplied. # into the board_info array. The default is target if no name is supplied.
# It returns the spawn id of the process that is the connection. # It returns the spawn id of the process that is the connection.
# #
proc remote_open { args } { proc remote_open { args } {
skipping to change at line 441 skipping to change at line 441
if { [llength $args] > 0 } { if { [llength $args] > 0 } {
set destfile [lindex $args 0] set destfile [lindex $args 0]
} else { } else {
set destfile [file tail $file] set destfile [file tail $file]
} }
if { ![is_remote $dest] } { if { ![is_remote $dest] } {
if { $destfile == "" || $destfile == $file } { if { $destfile == "" || $destfile == $file } {
return $file return $file
} else { } else {
verbose -log "Downloading on $dest to $destfile: $file" 2
set result [catch "exec cp -p $file $destfile" output] set result [catch "exec cp -p $file $destfile" output]
if {[regexp "same file|are identical" $output]} { if {[regexp "same file|are identical" $output]} {
set result 0 set result 0
set output "" set output ""
} else { } else {
# try to make sure we can read it # try to make sure we can read it
# and write it (in case we copy onto it again) # and write it (in case we copy onto it again)
catch {exec chmod u+rw $destfile} catch {exec chmod u+rw $destfile}
} }
if { $result != 0 || $output != "" } { if { $result != 0 || $output != "" } {
 End of changes. 3 change blocks. 
2 lines changed or deleted 3 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)