when the drain_children() callback function returns an error, set the
should_exit flag so that the drain_with_cb() macro can return that
error code via set_cr_error()
Fixes: https://tracker.ceph.com/issues/49065
Signed-off-by: Casey Bodley <cbodley@redhat.com>
(cherry picked from commit
d0916ecbb516363f16a454cfbf0363dec39018ff)
int r = (*cb)(stack_id, ret);
if (r < 0) {
drain_status.ret = r;
+ drain_status.should_exit = true;
num_cr_left = 0; /* need to drain all */
}
}