All of lore.kernel.org
 help / color / mirror / Atom feed
From: Simo Sorce <simo@redhat.com>
To: Linux NFS Mailing list <linux-nfs@vger.kernel.org>
Subject: [PATCH 1/3] Fix segfault when using -R option
Date: Tue,  2 Apr 2013 13:49:05 -0400	[thread overview]
Message-ID: <1364924947-16985-2-git-send-email-simo@redhat.com> (raw)
In-Reply-To: <1364924947-16985-1-git-send-email-simo@redhat.com>

The getopt string did not add : after the R option resulting in a sefgault
whenever -R was used as optarg is NULL and it is dereferenced.

Signed-off-by: Simo Sorce <simo@redhat.com>
---
 utils/gssd/gssd.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/utils/gssd/gssd.c b/utils/gssd/gssd.c
index 0be251781bacaa562270f773341126bc95ca6b45..07b1e52e6b84e9bcba96e7a63b0505ca7823482a 100644
--- a/utils/gssd/gssd.c
+++ b/utils/gssd/gssd.c
@@ -102,7 +102,7 @@ main(int argc, char *argv[])
 	char *progname;
 
 	memset(ccachesearch, 0, sizeof(ccachesearch));
-	while ((opt = getopt(argc, argv, "fvrlmnMp:k:d:t:R")) != -1) {
+	while ((opt = getopt(argc, argv, "fvrlmnMp:k:d:t:R:")) != -1) {
 		switch (opt) {
 			case 'f':
 				fg = 1;
-- 
1.7.1


  reply	other threads:[~2013-04-02 17:49 UTC|newest]

Thread overview: 31+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-04-02 17:49 [PATCH 0/3] Avoid DNS Reverse lookups when possible Simo Sorce
2013-04-02 17:49 ` Simo Sorce [this message]
2013-04-02 19:11   ` [PATCH 1/3] Fix segfault when using -R option Steve Dickson
2013-04-02 17:49 ` [PATCH 2/3] Avoid reverse resolution for server name Simo Sorce
2013-04-02 17:58   ` Myklebust, Trond
2013-04-02 18:08     ` Simo Sorce
2013-04-02 18:53       ` Jeff Layton
2013-04-02 18:21     ` Simo Sorce
2013-04-02 18:25       ` Steve Dickson
2013-04-02 18:44         ` Simo Sorce
2013-04-02 19:20     ` Steve Dickson
2013-04-02 19:32       ` [PATCH 0/2] Alternative patchset to avoid PTR lookups Simo Sorce
2013-04-02 19:32       ` [PATCH 1/2] Avoid reverse resolution for server name Simo Sorce
2013-04-08 13:39         ` Steve Dickson
2013-04-08 14:08           ` Simo Sorce
2013-04-09 17:15             ` Steve Dickson
2013-04-09 17:25               ` Simo Sorce
2013-04-09 17:35                 ` Steve Dickson
2013-04-09 18:02                   ` Simo Sorce
2013-04-09 18:54                   ` J. Bruce Fields
2013-04-09 19:12                     ` Steve Dickson
2013-04-09 19:22                       ` J. Bruce Fields
2013-04-10 10:43                         ` Jeff Layton
2013-04-10 14:53                         ` Steve Dickson
2013-04-02 19:32       ` [PATCH 2/2] Document new -z/-Z options Simo Sorce
2013-04-03 14:20         ` J. Bruce Fields
2013-04-03 14:35           ` Myklebust, Trond
2013-04-03 14:56             ` J. Bruce Fields
2013-04-03 15:10               ` Myklebust, Trond
2013-04-03 15:27                 ` Myklebust, Trond
2013-04-02 17:49 ` [PATCH 3/3] Document new -N option Simo Sorce

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=1364924947-16985-2-git-send-email-simo@redhat.com \
    --to=simo@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.