linux-btrfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Alexander Block <ablock84@googlemail.com>
To: linux-btrfs@vger.kernel.org
Cc: Alexander Block <ablock84@googlemail.com>
Subject: [PATCH 4/5] Btrfs-progs: make filesystem_cmd_group non const
Date: Sun, 24 Jun 2012 23:20:07 +0200	[thread overview]
Message-ID: <1340572808-30281-5-git-send-email-ablock84@googlemail.com> (raw)
In-Reply-To: <1340572808-30281-1-git-send-email-ablock84@googlemail.com>

Make filesystem_cmd_group non const so that btrfs fi prop can
generate the usage string at runtime. The commands member of
struct cmd_group is also non const now.

Signed-off-by: Alexander Block <ablock84@googlemail.com>
---
 cmds-filesystem.c |    2 +-
 commands.h        |    4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/cmds-filesystem.c b/cmds-filesystem.c
index a8f63b3..4c61233 100644
--- a/cmds-filesystem.c
+++ b/cmds-filesystem.c
@@ -536,7 +536,7 @@ static int cmd_label(int argc, char **argv)
 }
 }
 
-const struct cmd_group filesystem_cmd_group = {
+struct cmd_group filesystem_cmd_group = {
 	filesystem_cmd_group_usage, NULL, {
 		{ "df", cmd_df, cmd_df_usage, NULL, 0 },
 		{ "show", cmd_show, cmd_show_usage, NULL, 0 },
diff --git a/commands.h b/commands.h
index 64acf17..9405806 100644
--- a/commands.h
+++ b/commands.h
@@ -54,7 +54,7 @@ struct cmd_group {
 	const char * const *usagestr;
 	const char *infostr;
 
-	const struct cmd_struct commands[];
+	struct cmd_struct commands[];
 };
 
 /* btrfs.c */
@@ -81,7 +81,7 @@ void help_command_group(const struct cmd_group *grp, int argc, char **argv);
 int open_file_or_dir(const char *fname);
 
 extern const struct cmd_group subvolume_cmd_group;
-extern const struct cmd_group filesystem_cmd_group;
+extern struct cmd_group filesystem_cmd_group;
 extern const struct cmd_group balance_cmd_group;
 extern const struct cmd_group device_cmd_group;
 extern const struct cmd_group scrub_cmd_group;
-- 
1.7.10


  parent reply	other threads:[~2012-06-24 21:20 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-06-24 21:20 [PATCH 0/5] introduce btrfs filesystem property command Alexander Block
2012-06-24 21:20 ` [PATCH 1/5] Btrfs-progs: add BTRFS_IOC_SUBVOL_GET/SETFLAGS to ioctl.h Alexander Block
2012-06-24 21:20 ` [PATCH 2/5] Btrfs-progs: move skip_prefix and prefixcmp to utils.c Alexander Block
2012-06-24 21:20 ` [PATCH 3/5] Btrfs-progs: let get_label return the label instead of of printing it Alexander Block
2012-06-24 21:20 ` Alexander Block [this message]
2012-06-24 22:14   ` [PATCH 4/5] Btrfs-progs: make filesystem_cmd_group non const Alexander Block
2012-06-24 21:20 ` [PATCH 5/5] Btrfs-progs: introduce btrfs filesystem property command Alexander Block
2012-06-27  2:25 ` [PATCH 0/5] " Liu Bo
2012-06-27 11:08   ` Alexander Block
2012-06-28 13:08 ` Martin Steigerwald

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=1340572808-30281-5-git-send-email-ablock84@googlemail.com \
    --to=ablock84@googlemail.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).