diff options
author | Bryn M. Reeves <breeves@redhat.com> | 2007-06-08 22:38:48 +0000 |
---|---|---|
committer | Bryn M. Reeves <breeves@redhat.com> | 2007-06-08 22:38:48 +0000 |
commit | 944cac939cac7d0b90dffd064cc69cbaebaed1ca (patch) | |
tree | 54ccd52a7f249ea8191a8025ae03397a8b1e7683 /lib/format_text/archive.c | |
parent | c221b0bc2197f8b5233c53698d760a8eb755344d (diff) | |
download | lvm2-944cac939cac7d0b90dffd064cc69cbaebaed1ca.tar.gz |
Allow vgcfgrestore to list metadata backup files using -f
Diffstat (limited to 'lib/format_text/archive.c')
-rw-r--r-- | lib/format_text/archive.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/lib/format_text/archive.c b/lib/format_text/archive.c index c42581c16..ca94c7424 100644 --- a/lib/format_text/archive.c +++ b/lib/format_text/archive.c @@ -362,6 +362,22 @@ int archive_list(struct cmd_context *cmd, const char *dir, const char *vgname) return 1; } +int archive_list_file(struct cmd_context *cmd, const char *file) +{ + struct archive_file af; + + af.path = (char *)file; + + if (!path_exists(af.path)) { + log_err("Archive file %s not found.", af.path); + return 0; + } + + _display_archive(cmd, &af); + + return 1; +} + int backup_list(struct cmd_context *cmd, const char *dir, const char *vgname) { struct archive_file af; |