public inbox for linux-nfs@vger.kernel.org
 help / color / mirror / Atom feed
From: Steve Dickson <steved@redhat.com>
To: Linux NFS Mailing list <linux-nfs@vger.kernel.org>
Subject: [PATCH] rpc.statd: Allow usage messages to be displayed when statd is running.
Date: Sat, 18 Jan 2014 11:51:15 -0500	[thread overview]
Message-ID: <1390063875-11456-1-git-send-email-steved@redhat.com> (raw)

Signed-off-by: Steve Dickson <steved@redhat.com>
---
 utils/statd/statd.c | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/utils/statd/statd.c b/utils/statd/statd.c
index 8c51bcc..8f31111 100644
--- a/utils/statd/statd.c
+++ b/utils/statd/statd.c
@@ -238,12 +238,6 @@ int main (int argc, char **argv)
 	/* Set hostname */
 	MY_NAME = NULL;
 
-	/* Refuse to start if another statd is running */
-	if (nfs_probe_statd()) {
-		fprintf(stderr, "Statd service already running!\n");
-		exit(1);
-	}
-
 	/* Process command line switches */
 	while ((arg = getopt_long(argc, argv, "h?vVFNH:dn:p:o:P:L", longopts, NULL)) != EOF) {
 		switch (arg) {
@@ -306,6 +300,12 @@ int main (int argc, char **argv)
 		}
 	}
 
+	/* Refuse to start if another statd is running */
+	if (nfs_probe_statd()) {
+		fprintf(stderr, "Statd service already running!\n");
+		exit(1);
+	}
+
 	if (port == out_port && port != 0) {
 		fprintf(stderr, "Listening and outgoing ports cannot be the same!\n");
 		exit(-1);
-- 
1.8.3.1


                 reply	other threads:[~2014-01-18 16:49 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1390063875-11456-1-git-send-email-steved@redhat.com \
    --to=steved@redhat.com \
    --cc=linux-nfs@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox