linux-btrfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Rakesh Pandit <rakesh@tuxera.com>
To: <linux-btrfs@vger.kernel.org>
Subject: [PATCH] Btrfs-progs: cmds-subvolume: use parameter str instead of optarg
Date: Sat, 19 Apr 2014 03:14:29 +0300	[thread overview]
Message-ID: <20140419001428.GA5788@hercules.tuxera.com> (raw)

Fix unused parameter str (commit e8cfa3c8): get_subvolid was called
with optarg passed as str, but get_subvolid kept using optarg.

Signed-off-by: Rakesh Pandit <rakesh@tuxera.com>
---
 cmds-subvolume.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/cmds-subvolume.c b/cmds-subvolume.c
index bd81a8f..639fb10 100644
--- a/cmds-subvolume.c
+++ b/cmds-subvolume.c
@@ -596,9 +596,9 @@ static int get_subvolid(const char *str, u64 *subvolid)
 {
 	char *p;
 	errno = 0;
-	*subvolid = strtoull(optarg, &p, 10);
+	*subvolid = strtoull(str, &p, 10);
 	if (errno || *p != '\0') {
-		fprintf(stderr, "ERROR: invalid subvolume id '%s'\n", optarg);
+		fprintf(stderr, "ERROR: invalid subvolume id '%s'\n", str);
 		return -EINVAL;
 	}
 	return 0;
-- 
1.8.5.3


                 reply	other threads:[~2014-04-19  0:14 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=20140419001428.GA5788@hercules.tuxera.com \
    --to=rakesh@tuxera.com \
    --cc=linux-btrfs@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;
as well as URLs for NNTP newsgroup(s).