diff options
author | Alasdair Kergon <agk@redhat.com> | 2007-01-18 22:15:04 +0000 |
---|---|---|
committer | Alasdair Kergon <agk@redhat.com> | 2007-01-18 22:15:04 +0000 |
commit | 09e206d3933ecab27678293cd4ce7505afcf1caf (patch) | |
tree | 83700b50a079b494064d6f53a43c9a38aa148e7e | |
parent | 122337ba0d14009239067e1f177311145c3cdbcf (diff) | |
download | lvm2-09e206d3933ecab27678293cd4ce7505afcf1caf.tar.gz lvm2-09e206d3933ecab27678293cd4ce7505afcf1caf.tar.xz lvm2-09e206d3933ecab27678293cd4ce7505afcf1caf.zip |
Suppress 'Unrecognised field' error if report field is 'help'.
-rw-r--r-- | WHATS_NEW_DM | 1 | ||||
-rw-r--r-- | libdm/libdm-report.c | 5 |
2 files changed, 4 insertions, 2 deletions
diff --git a/WHATS_NEW_DM b/WHATS_NEW_DM index f0498a94..3afa7ecf 100644 --- a/WHATS_NEW_DM +++ b/WHATS_NEW_DM @@ -1,5 +1,6 @@ Version 1.02.16 - =================================== + Suppress 'Unrecognised field' error if report field is 'help'. Add --separator and --sort to dmsetup (unused). Make alignment flag optional when specifying report fields. diff --git a/libdm/libdm-report.c b/libdm/libdm-report.c index 3f835f0f..c6852a9a 100644 --- a/libdm/libdm-report.c +++ b/libdm/libdm-report.c @@ -416,8 +416,9 @@ static int _parse_options(struct dm_report *rh, const char *format) if (!_field_match(rh, ws, (size_t) (we - ws))) { _display_fields(rh); log_print(" "); - log_error("dm_report: Unrecognised field: %.*s", - (int) (we - ws), ws); + if (strcasecmp(ws, "help") && strcmp(ws, "?")) + log_error("Unrecognised field: %.*s", + (int) (we - ws), ws); return 0; } } |