[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[commits] r2018 - in /branches/eglibc-2_5/libc: ChangeLog.eglibc scripts/cross-test-ssh.sh



Author: joseph
Date: Wed Apr 18 16:55:49 2007
New Revision: 2018

Log:
	* scripts/cross-test-ssh.sh: Use printf in place of echo.

Modified:
    branches/eglibc-2_5/libc/ChangeLog.eglibc
    branches/eglibc-2_5/libc/scripts/cross-test-ssh.sh

Modified: branches/eglibc-2_5/libc/ChangeLog.eglibc
==============================================================================
--- branches/eglibc-2_5/libc/ChangeLog.eglibc (original)
+++ branches/eglibc-2_5/libc/ChangeLog.eglibc Wed Apr 18 16:55:49 2007
@@ -1,3 +1,7 @@
+2007-04-18  Joseph Myers  <joseph@xxxxxxxxxxxxxxxx>
+
+	* scripts/cross-test-ssh.sh: Use printf in place of echo.
+
 2007-04-16  Joseph Myers  <joseph@xxxxxxxxxxxxxxxx>
 
 	* sysdeps/powerpc/fpu/bits/fenvinline.h: Test _SOFT_FLOAT together

Modified: branches/eglibc-2_5/libc/scripts/cross-test-ssh.sh
==============================================================================
--- branches/eglibc-2_5/libc/scripts/cross-test-ssh.sh (original)
+++ branches/eglibc-2_5/libc/scripts/cross-test-ssh.sh Wed Apr 18 16:55:49 2007
@@ -76,7 +76,7 @@
 
 # Return all input as a properly quoted Bourne shell string.
 bourne_quote () {
-    echo -n '"'
+    printf '%s' '"'
     sed -n \
         -e '1h' \
         -e '2,$H' \
@@ -84,7 +84,7 @@
               s/["$\`]/\\&/g
               p
              }'
-    echo -n '"'
+    printf '%s' '"'
 }
 
 # Echo all lines of input except those starting with 'export VAR=',
@@ -109,8 +109,8 @@
 # Transform the current argument list into a properly quoted Bourne shell
 # command string.
 command="$(for word in "$@"; do
-               echo -n "$word" | bourne_quote
-               echo -n ' '
+               printf '%s' "$word" | bourne_quote
+               printf '%s' ' '
            done)"
 
 # Add commands to set environment variables and the current directory.
@@ -122,4 +122,4 @@
 # passes them to some shell.  We want to force the use of /bin/sh,
 # so we need to re-quote the whole command to ensure it appears as
 # the sole argument of the '-c' option.
-$ssh "$host" /bin/sh -c "$(echo "${command}" | bourne_quote)"
+$ssh "$host" /bin/sh -c "$(printf '%s\n' "${command}" | bourne_quote)"