Code review comment for lp:~thomas-voss/dbus-cpp/fix-invalid-reads-in-executor

Revision history for this message
Alberto Aguirre (albaguirre) wrote :

Looks good.

135 + std::lock_guard<std::mutex> lg{wrapper->pending_call->guard};

One small nit:

148 + void notify_locked(const Message::Ptr& msg)

Maybe just take the a std::lock_guard const& to enforce the locked constraint?

466 + auto ec = std::make_shared<CountingEventCollector>(5000);
467 +
468 + std::thread t1{[dbus, ec]() {invoke_list_names_n_times_and_update_event_collector(dbus, 1000, ec);}};
469 + std::thread t2{[dbus, ec]() {invoke_list_names_n_times_and_update_event_collector(dbus, 1000, ec);}};
470 + std::thread t3{[dbus, ec]() {invoke_list_names_n_times_and_update_event_collector(dbus, 1000, ec);}};
471 + std::thread t4{[dbus, ec]() {invoke_list_names_n_times_and_update_event_collector(dbus, 1000, ec);}};
472 + std::thread t5{[dbus, ec]() {invoke_list_names_n_times_and_update_event_collector(dbus, 1000, ec);}};

I guess CI is too slow...maybe 100 per thread should be enough?

« Back to merge proposal