summaryrefslogtreecommitdiff
path: root/utils
diff options
context:
space:
mode:
authorGuillem Jover <guillem@debian.org>2008-01-17 06:14:43 +0200
committerGuillem Jover <guillem@debian.org>2008-01-17 23:30:05 +0200
commit8ef0764aacf913cb70ea90bb6d33910d92280a51 (patch)
tree17ca4cd50507098a7f05b34a1e0f26a04273e38d /utils
parentf7509a5532ad7496b7d96765caac9e7adc2f9395 (diff)
downloaddpkg-8ef0764aacf913cb70ea90bb6d33910d92280a51.tar.gz
s-s-d: Move version output from --help to --version
Diffstat (limited to 'utils')
-rw-r--r--utils/start-stop-daemon.c16
1 files changed, 10 insertions, 6 deletions
diff --git a/utils/start-stop-daemon.c b/utils/start-stop-daemon.c
index c384031e3..7994b5b52 100644
--- a/utils/start-stop-daemon.c
+++ b/utils/start-stop-daemon.c
@@ -338,9 +338,6 @@ static void
do_help(void)
{
printf(
-"start-stop-daemon %s for Debian - small and fast C version written by\n"
-"Marek Michalkiewicz <marekm@i17linuxb.ists.pwr.wroc.pl>, public domain.\n"
-"\n"
"Usage: start-stop-daemon [<option> ...] <command>\n"
"\n"
"Commands:\n"
@@ -379,8 +376,15 @@ do_help(void)
"or <schedule> may be just <timeout>, meaning <signal>/<timeout>/KILL/<timeout>\n"
"\n"
"Exit status: 0 = done 1 = nothing done (=> 0 if --oknodo)\n"
-" 3 = trouble 2 = with --retry, processes wouldn't die\n",
- VERSION);
+" 3 = trouble 2 = with --retry, processes wouldn't die\n");
+}
+
+static void
+do_version(void)
+{
+ printf("start-stop-daemon %s for Debian\n\n", VERSION)
+
+ printf("Written by Marek Michalkiewicz, public domain.\n");
}
static void
@@ -597,7 +601,7 @@ parse_options(int argc, char * const *argv)
start = 1;
break;
case 'V': /* --version */
- printf("start-stop-daemon " VERSION "\n");
+ do_version();
exit(0);
case 'a': /* --startas <pathname> */
startas = optarg;