You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
gentoo-overlay/dev-perl/Gearman-Server/files/Gearman-Server-1.09-Use-san...

34 lines
966 B

From 6d8055b1d44d745f194665458674c6e03f48f322 Mon Sep 17 00:00:00 2001
From: Robin H. Johnson <robbat2@gentoo.org>
Date: Sat, 12 May 2007 22:16:37 -0700
Subject: [PATCH gearman] Use saner name in process listing.
Normally the binary will turn up in the process list as:
/usr/bin/perl $SCRIPTNAME
By adding a single line, we can make it be simply '$SCRIPTNAME'.
This makes writing init.d scripts signficently easier.
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
---
server/gearmand | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/server/gearmand b/server/gearmand
index 2d8bd6b..148b1f9 100755
--- a/server/gearmand
+++ b/server/gearmand
@@ -94,6 +94,9 @@ my (
);
my $conf_port = 7003;
+# Rename binary in process list to make init scripts saner
+$0 = $_ = $0;
+
Getopt::Long::GetOptions(
'd|daemonize' => \$daemonize,
'p|port=i' => \$conf_port,
--
1.5.1.4