mirror of
https://github.com/ceph/ceph
synced 2025-01-19 01:21:49 +00:00
Merge pull request #12723 from gaurav36/rbd-remove-unused-condition
rbd: remove unused condition within group action handler Reviewed-by: Jason Dillaman <dillaman@redhat.com>
This commit is contained in:
commit
7e40baaae4
@ -261,11 +261,13 @@ int execute_list_images(const po::variables_map &vm) {
|
||||
|
||||
if (r == -ENOENT)
|
||||
r = 0;
|
||||
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
if (f)
|
||||
f->open_array_section("consistency_groups");
|
||||
|
||||
for (auto i : images) {
|
||||
std::string image_name = i.name;
|
||||
int64_t pool_id = i.pool;
|
||||
@ -274,8 +276,6 @@ int execute_list_images(const po::variables_map &vm) {
|
||||
if (cls::rbd::GROUP_IMAGE_LINK_STATE_INCOMPLETE == state) {
|
||||
state_string = "incomplete";
|
||||
}
|
||||
if (r < 0)
|
||||
return r;
|
||||
if (f) {
|
||||
f->dump_string("image name", image_name);
|
||||
f->dump_int("pool id", pool_id);
|
||||
@ -283,6 +283,7 @@ int execute_list_images(const po::variables_map &vm) {
|
||||
} else
|
||||
std::cout << pool_id << "." << image_name << " " << state_string << std::endl;
|
||||
}
|
||||
|
||||
if (f) {
|
||||
f->close_section();
|
||||
f->flush(std::cout);
|
||||
|
Loading…
Reference in New Issue
Block a user