Revert unnecessary use of /bin/echo -n
authorSteve Langasek <steve.langasek@canonical.com>
Wed, 15 May 2013 08:47:03 +0000 (10:47 +0200)
committerDidier Raboud <odyx@debian.org>
Wed, 15 May 2013 08:49:01 +0000 (10:49 +0200)
In response to bug #602038, the init-functions scripts in lsb-base have been
changed to use /bin/echo -n instead of echo -n.  This results in a lot of
added forks which are unnecessary and inappropriate: 'echo -n' is guaranteed
by Debian policy to be supported by the shell.

Closes: #708337
init-functions

index 046dfb9b4416495bbfc75d90da70675922d8dff5..cb8874c9efb995e0e9fe70cbe7a58ea87e91f5ce 100644 (file)
@@ -280,7 +280,7 @@ log_begin_msg () {
     if [ -z "${1:-}" ]; then
         return 1
     fi
-    /bin/echo -n "$@" || true
+    echo -n "$@" || true
     log_begin_msg_post "$@"
 }
 
@@ -305,11 +305,11 @@ log_daemon_msg () {
     log_daemon_msg_pre "$@"
 
     if [ -z "${2:-}" ]; then
-        /bin/echo -n "$1:" || true
+        echo -n "$1:" || true
         return
     fi
     
-    /bin/echo -n "$1: $2" || true
+    echo -n "$1: $2" || true
     log_daemon_msg_post "$@"
 }
 
@@ -332,7 +332,7 @@ log_progress_msg () {
     if [ -z "${1:-}" ]; then
         return 1
     fi
-    /bin/echo -n " $@" || true
+    echo -n " $@" || true
 }
 
 
@@ -379,12 +379,12 @@ log_action_msg () {
 
 log_action_begin_msg () {
     log_action_begin_msg_pre "$@"
-    /bin/echo -n "$@..." || true
+    echo -n "$@..." || true
     log_action_begin_msg_post "$@"
 }
 
 log_action_cont_msg () {
-    /bin/echo -n "$@..." || true
+    echo -n "$@..." || true
 }
 
 log_action_end_msg () {