public inbox for cluster-cvs@sourceware.org
help / color / mirror / Atom feed
From: Steven Whitehouse <swhiteho@fedoraproject.org>
To: cluster-cvs-relay@redhat.com
Subject: cluster: STABLE3 - Remove unused code from various places
Date: Wed, 27 May 2009 10:20:00 -0000	[thread overview]
Message-ID: <20090527101927.612AA120356@lists.fedorahosted.org> (raw)

Gitweb:        http://git.fedorahosted.org/git/cluster.git?p=cluster.git;a=commitdiff;h=f6ef6e42bc9512a5a7d46c1a1be42848cc25ebaa
Commit:        f6ef6e42bc9512a5a7d46c1a1be42848cc25ebaa
Parent:        207d205a81be6e60cd1891ad0dd20824bf6813ee
Author:        Steven Whitehouse <steve@dolmen.chygwyn.com>
AuthorDate:    Mon Mar 23 14:21:22 2009 +0000
Committer:     Steven Whitehouse <swhiteho@redhat.com>
CommitterDate: Wed May 27 09:47:14 2009 +0100

Remove unused code from various places

The last few #if 0 blocks of code are now gone.

Signed-off-by: Steven Whitehouse <swhiteho@redhat.com>
---
 gfs2/mkfs/main.c        |    4 ----
 gfs2/mount/mount.gfs2.c |   24 ------------------------
 gfs2/quota/check.c      |   31 -------------------------------
 3 files changed, 0 insertions(+), 59 deletions(-)

diff --git a/gfs2/mkfs/main.c b/gfs2/mkfs/main.c
index 2707262..9471c6f 100644
--- a/gfs2/mkfs/main.c
+++ b/gfs2/mkfs/main.c
@@ -42,10 +42,6 @@ main(int argc, char *argv[])
 		main_mkfs(argc, argv);
 	else if (!strcmp(whoami, "gfs2_grow"))
 		main_grow(argc, argv);
-#if 0
-	else if (!strcmp(whoami, "gfs2_shrink"))
-		main_shrink(argc, argv);
-#endif
 	else
 		die("I don't know who I am!\n");
 
diff --git a/gfs2/mount/mount.gfs2.c b/gfs2/mount/mount.gfs2.c
index 4ae8bbe..f84dfde 100644
--- a/gfs2/mount/mount.gfs2.c
+++ b/gfs2/mount/mount.gfs2.c
@@ -155,30 +155,6 @@ static void umount_lockproto(char *proto, struct mount_options *mo,
 		lock_dlm_leave(mo, sb, mnterr);
 }
 
-#if 0
-static void check_sys_fs(char *fsname)
-{
-	DIR *d;
-	struct dirent *de;
-
-	d = opendir("/sys/fs/");
-	if (!d)
-		die("no /sys/fs/ directory found: %d\n", errno);
-
-	while ((de = readdir(d))) {
-		if (strnlen(fsname, 5) != strnlen(de->d_name, 5))
-			continue;
-		if (!strncmp(fsname, de->d_name, strnlen(fsname, 5))) {
-			closedir(d);
-			return;
-		}
-	}
-	closedir(d);
-	die("fs type \"%s\" not found in /sys/fs/, is the module loaded?\n",
-	    fsname);
-}
-#endif
-
 int main(int argc, char **argv)
 {
 	struct mount_options mo;
diff --git a/gfs2/quota/check.c b/gfs2/quota/check.c
index 118758b..7d1ec5b 100644
--- a/gfs2/quota/check.c
+++ b/gfs2/quota/check.c
@@ -267,27 +267,6 @@ out:
 }
 
 /**
- * print_list - print the contents of an ID list
- * @str: a string describing the list
- * @list: the list
- *
- */
-
-static void
-print_list(const char *str, osi_list_t *list)
-{
-#if 0
-	osi_list_t *tmp;
-	values_t *v;
-
-	for (tmp = list->next; tmp != list; tmp = tmp->next) {
-		v = osi_list_entry(tmp, values_t, v_list);
-		printf("%s %10u: %"PRId64"\n", str, v->v_id, v->v_blocks);
-	}
-#endif
-}
-
-/**
  * do_compare - compare to ID lists and see if they match
  * @type: the type of list (UID or GID)
  * @fs_list: the list derived from scaning the FS
@@ -426,11 +405,6 @@ do_check(struct gfs2_sbd *sdp, commandline_t *comline)
 	scan_fs(device, comline->filesystem, &fs_uid, &fs_gid, &hl);
 	read_quota_file(sdp, comline, &qf_uid, &qf_gid);
 
-	print_list("fs user ", &fs_uid);
-	print_list("fs group", &fs_gid);
-	print_list("qf user ", &qf_uid);
-	print_list("qf group", &qf_gid);
-
 	mismatch = do_compare("user", &fs_uid, &qf_uid);
 	mismatch |= do_compare("group", &fs_gid, &qf_gid);
 
@@ -565,11 +539,6 @@ do_quota_init(struct gfs2_sbd *sdp, commandline_t *comline)
 	v->v_blocks = 0;
 	osi_list_add(&v->v_list, &qf_gid);
 
-	print_list("fs user ", &fs_uid);
-	print_list("fs group", &fs_gid);
-	print_list("qf user ", &qf_uid);
-	print_list("qf group", &qf_gid);
-
 	set_list(sdp, comline, TRUE, &qf_uid, 0);
 	set_list(sdp, comline, FALSE, &qf_gid, 0);
 	set_list(sdp, comline, TRUE, &fs_uid, 1);


             reply	other threads:[~2009-05-27 10:20 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-05-27 10:20 Steven Whitehouse [this message]
  -- strict thread matches above, loose matches on Subject: below --
2009-03-23 17:26 Steven Whitehouse

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=20090527101927.612AA120356@lists.fedorahosted.org \
    --to=swhiteho@fedoraproject.org \
    --cc=cluster-cvs-relay@redhat.com \
    /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).