On 08/20/2013 11:15 PM, [email protected] wrote:
From: Jackie Huang <[email protected]>

Signed-off-by: Li Wang <[email protected]>
Signed-off-by: Jackie Huang <[email protected]>
---
  .../openssh/openssh-6.2p2/init                     |   14 +++++++++++++-
  1 files changed, 13 insertions(+), 1 deletions(-)

diff --git a/meta/recipes-connectivity/openssh/openssh-6.2p2/init 
b/meta/recipes-connectivity/openssh/openssh-6.2p2/init
index 12fb79b..72c5822 100644
--- a/meta/recipes-connectivity/openssh/openssh-6.2p2/init
+++ b/meta/recipes-connectivity/openssh/openssh-6.2p2/init
@@ -1,6 +1,9 @@
  #! /bin/sh
  set -e

+# source function library
+. /etc/init.d/functions
+
  # /etc/init.d/ssh: start and stop the OpenBSD "secure shell" daemon

  test -x /usr/sbin/sshd || exit 0
@@ -54,6 +57,11 @@ check_keys() {
        fi
  }

+rh_status() {
+       status /usr/sbin/sshd
+       return $?
+}
+
  export PATH="${PATH:+$PATH:}/usr/sbin:/sbin"

  case "$1" in
@@ -92,8 +100,12 @@ case "$1" in
        echo "."
        ;;

+  status)
+       rh_status

Why rh_status here and in the "at" script? Can't you just do the status /usr/bin/sshd directly here?

+  ;;
+
    *)
-       echo "Usage: /etc/init.d/ssh {start|stop|reload|force-reload|restart}"
+       echo "Usage: /etc/init.d/ssh 
{start|stop|status|reload|force-reload|restart}"
        exit 1
  esac


_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core

Reply via email to