public inbox for lvm2-cvs@sourceware.org
help / color / mirror / Atom feed
From: wysochanski@sourceware.org
To: lvm-devel@redhat.com, lvm2-cvs@sourceware.org
Subject: LVM2/libdm libdm-report.c
Date: Mon, 19 Jan 2009 20:53:00 -0000	[thread overview]
Message-ID: <20090119205335.20737.qmail@sourceware.org> (raw)

CVSROOT:	/cvs/lvm2
Module name:	LVM2
Changes by:	wysochanski@sourceware.org	2009-01-19 20:53:35

Modified files:
	libdm          : libdm-report.c 

Log message:
	Rename _parse_options() to _parse_fields() for naming consistency.
	
	In libdm, we only ever use 'fields', while the tools use 'options' and
	'fields' interchangeably.
	
	Ideally it would be good to use 'fields' consistently everywhere.
	However, 'options' most likely comes from the tool commandline '-o' and
	'--options' which cannot be changed.

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/LVM2/libdm/libdm-report.c.diff?cvsroot=lvm2&r1=1.28&r2=1.29

--- LVM2/libdm/libdm-report.c	2009/01/10 03:14:24	1.28
+++ LVM2/libdm/libdm-report.c	2009/01/19 20:53:35	1.29
@@ -491,8 +491,8 @@
 	return 0;
 }
 
-static int _parse_options(struct dm_report *rh, const char *format,
-			  unsigned report_type_only)
+static int _parse_fields(struct dm_report *rh, const char *format,
+			 unsigned report_type_only)
 {
 	const char *ws;		/* Word start */
 	const char *we = format;	/* Word end */
@@ -562,9 +562,9 @@
 	memset(rh, 0, sizeof(*rh));
 
 	/*
-	 * rh->report_types is updated in _parse_options() and _parse_keys()
+	 * rh->report_types is updated in _parse_fields() and _parse_keys()
 	 * to contain all types corresponding to the fields specified by
-	 * options or keys.
+	 * fields or keys.
 	 */
 	if (report_types)
 		rh->report_types = *report_types;
@@ -606,14 +606,14 @@
 	 * the field lists twice.  The first time we only update the report type.
 	 * FIXME Use one pass instead and expand the "all" field afterwards.
 	 */
-	if (!_parse_options(rh, output_fields, 1) ||
+	if (!_parse_fields(rh, output_fields, 1) ||
 	    !_parse_keys(rh, sort_keys, 1)) {
 		dm_report_free(rh);
 		return NULL;
 	}
 
 	/* Generate list of fields for output based on format string & flags */
-	if (!_parse_options(rh, output_fields, 0) ||
+	if (!_parse_fields(rh, output_fields, 0) ||
 	    !_parse_keys(rh, sort_keys, 0)) {
 		dm_report_free(rh);
 		return NULL;


             reply	other threads:[~2009-01-19 20:53 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-01-19 20:53 wysochanski [this message]
  -- strict thread matches above, loose matches on Subject: below --
2010-11-01 13:50 prajnoha
2010-02-15 18:36 zkabelac
2010-01-07 14:32 zkabelac
2009-01-10  3:14 agk

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=20090119205335.20737.qmail@sourceware.org \
    --to=wysochanski@sourceware.org \
    --cc=lvm-devel@redhat.com \
    --cc=lvm2-cvs@sourceware.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 read-only IMAP folder(s) and NNTP newsgroup(s).