In the libcephfs test case, it will run handreds of threads in
parallel, it will possibly reach the open files limit, but there
won't useful logs about what has happened.
This will just throw a system error, just like:
C++ exception with description "(24) Too many open files" thrown in the test body.
Fixes: https://tracker.ceph.com/issues/43039
Signed-off-by: Xiubo Li <xiubli@redhat.com>
for (unsigned worker_id = 0; worker_id < num_workers; ++worker_id) {
Worker *w = create_worker(cct, type, worker_id);
- w->center.init(InitEventNumber, worker_id, type);
+ int ret = w->center.init(InitEventNumber, worker_id, type);
+ if (ret)
+ throw std::system_error(-ret, std::generic_category());
workers.push_back(w);
}
}