X-Git-Url: http://andersk.mit.edu/gitweb/gssapi-openssh.git/blobdiff_plain/cdd66111973295c976f1a0bb57f571eba0513757..476861787f6e1b8a6c6af9307a15b9e57cb979dc:/openssh/contrib/ssh-copy-id diff --git a/openssh/contrib/ssh-copy-id b/openssh/contrib/ssh-copy-id index a1c0a92..acd36d3 100644 --- a/openssh/contrib/ssh-copy-id +++ b/openssh/contrib/ssh-copy-id @@ -11,7 +11,7 @@ if [ "-i" = "$1" ]; then shift # check if we have 2 parameters left, if so the first is the new ID file if [ -n "$2" ]; then - if expr "$1" : ".*\.pub" ; then + if expr "$1" : ".*\.pub" > /dev/null ; then ID_FILE="$1" else ID_FILE="$1.pub" @@ -24,7 +24,7 @@ else fi fi -if [ -z "`eval $GET_ID`" -a -r "${ID_FILE}" ] ; then +if [ -z "`eval $GET_ID`" ] && [ -r "${ID_FILE}" ] ; then GET_ID="cat ${ID_FILE}" fi