From eecbd583ac0f0524b8ac6e183d76557431d1bc21 Mon Sep 17 00:00:00 2001 From: Brian Foster Date: Wed, 19 Feb 2014 11:52:24 +1100 Subject: [PATCH] xfs_io: set argmax to 1 for imap command The imap command supports an optional argument to specify the number of inode records to capture per ioctl(), but argmax is currently set to 0. This leads to an error if an argument is provided on the command line. Set argmax to 1 to support the optional argument. Signed-off-by: Brian Foster Reviewed-by: Jie Liu Signed-off-by: Dave Chinner --- io/imap.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/io/imap.c b/io/imap.c index 0a4f14e9a..4f3f88350 100644 --- a/io/imap.c +++ b/io/imap.c @@ -67,7 +67,7 @@ imap_init(void) imap_cmd.name = "imap"; imap_cmd.cfunc = imap_f; imap_cmd.argmin = 0; - imap_cmd.argmax = 0; + imap_cmd.argmax = 1; imap_cmd.args = _("[nentries]"); imap_cmd.flags = CMD_NOMAP_OK; imap_cmd.oneline = _("inode map for filesystem of current file"); -- 2.47.2