netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jan Synacek <jsynacek@redhat.com>
To: yoshfuji@linux-ipv6.org
Cc: netdev@vger.kernel.org, Jan Synacek <jsynacek@redhat.com>
Subject: [PATCH 2/2] ninfod: Make -v exit correctly.
Date: Wed, 23 Jan 2013 14:37:45 +0100	[thread overview]
Message-ID: <1358948265-20867-3-git-send-email-jsynacek@redhat.com> (raw)
In-Reply-To: <1358948265-20867-1-git-send-email-jsynacek@redhat.com>

Signed-off-by: Jan Synacek <jsynacek@redhat.com>
---
 ninfod/ninfod.c | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/ninfod/ninfod.c b/ninfod/ninfod.c
index 58b15aa..52cf446 100644
--- a/ninfod/ninfod.c
+++ b/ninfod/ninfod.c
@@ -639,12 +639,15 @@ int main (int argc, char **argv)
 
 	parse_args(argc, argv);
 
-	if (opt_h || opt_v)
-		print_copying();
 	if (opt_h) {
+		print_copying();
 		print_usage();
 		exit(1);
 	}
+	if (opt_v) {
+		print_copying();
+		return 0;
+	}
 
 	limit_capabilities();
 
-- 
1.8.1

      parent reply	other threads:[~2013-01-23 13:37 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-01-23 13:37 [PATCH 0/2] iputils: ninfod minor changes Jan Synacek
2013-01-23 13:37 ` [PATCH 1/2] ninfod: Call limit/drop_capabilities() and open_sock() after checking for -h or -v Jan Synacek
2013-01-23 13:37 ` Jan Synacek [this message]

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=1358948265-20867-3-git-send-email-jsynacek@redhat.com \
    --to=jsynacek@redhat.com \
    --cc=netdev@vger.kernel.org \
    --cc=yoshfuji@linux-ipv6.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;
as well as URLs for NNTP newsgroup(s).