Message ID | 33b6a64202469681f7b27892f2c1c5fe4884a60e.1707513011.git.mjt@tls.msk.ru |
---|---|
State | New |
Headers | show |
Series | qemu-img: refersh options and --help handling | expand |
On Sat, Feb 10, 2024 at 12:22:26AM +0300, Michael Tokarev wrote: > Signed-off-by: Michael Tokarev <mjt@tls.msk.ru> > --- > qemu-img.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/qemu-img.c b/qemu-img.c > index 3ae07bfae0..ad7fa033b1 100644 > --- a/qemu-img.c > +++ b/qemu-img.c > @@ -843,8 +843,8 @@ static int img_check(const img_cmd_t *ccmd, int argc, char **argv) > } else if (!strcmp(optarg, "all")) { > fix = BDRV_FIX_LEAKS | BDRV_FIX_ERRORS; > } else { > - error_exit(ccmd, "Unknown option value for -r " > - "(expecting 'leaks' or 'all'): %s", optarg); > + error_exit(ccmd, > + "--repair expects 'leaks' or 'all' not '%s'", optarg); > } Should we say '--repair/-r expects...' since we don't know which the user passed Either way Reviewed-by: Daniel P. Berrangé <berrange@redhat.com> With regards, Daniel
diff --git a/qemu-img.c b/qemu-img.c index 3ae07bfae0..ad7fa033b1 100644 --- a/qemu-img.c +++ b/qemu-img.c @@ -843,8 +843,8 @@ static int img_check(const img_cmd_t *ccmd, int argc, char **argv) } else if (!strcmp(optarg, "all")) { fix = BDRV_FIX_LEAKS | BDRV_FIX_ERRORS; } else { - error_exit(ccmd, "Unknown option value for -r " - "(expecting 'leaks' or 'all'): %s", optarg); + error_exit(ccmd, + "--repair expects 'leaks' or 'all' not '%s'", optarg); } break; case OPTION_OUTPUT:
Signed-off-by: Michael Tokarev <mjt@tls.msk.ru> --- qemu-img.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)