@@ -173,7 +173,7 @@ bool FfiClient::isInitialized() const noexcept {
173173FfiClient::ListenerId
174174FfiClient::AddListener (const FfiClient::Listener &listener) {
175175 const std::scoped_lock<std::mutex> guard (lock_);
176- FfiClient::ListenerId id = next_listener_id++;
176+ const FfiClient::ListenerId id = next_listener_id++;
177177 listeners_[id] = listener;
178178 return id;
179179}
@@ -191,7 +191,7 @@ FfiClient::sendRequest(const proto::FfiRequest &request) const {
191191 }
192192 const uint8_t *resp_ptr = nullptr ;
193193 size_t resp_len = 0 ;
194- FfiHandleId handle =
194+ const FfiHandleId handle =
195195 livekit_ffi_request (reinterpret_cast <const uint8_t *>(bytes.data ()),
196196 bytes.size (), &resp_ptr, &resp_len);
197197 if (handle == INVALID_HANDLE) {
@@ -455,7 +455,7 @@ FfiClient::getTrackStatsAsync(uintptr_t track_handle) {
455455 get_stats_req->set_request_async_id (async_id);
456456
457457 try {
458- proto::FfiResponse resp = sendRequest (req);
458+ const proto::FfiResponse resp = sendRequest (req);
459459 if (!resp.has_get_stats ()) {
460460 logAndThrow (" FfiResponse missing get_stats" );
461461 }
@@ -502,7 +502,7 @@ FfiClient::publishTrackAsync(std::uint64_t local_participant_handle,
502502 }
503503
504504 const proto::OwnedTrackPublication &pub = cb.publication ();
505- pr.set_value (std::move ( pub) );
505+ pr.set_value (pub);
506506 });
507507
508508 // Build and send the request
@@ -701,7 +701,7 @@ FfiClient::subscribeDataTrack(std::uint64_t track_handle,
701701 }
702702
703703 try {
704- proto::FfiResponse resp = sendRequest (req);
704+ const proto::FfiResponse resp = sendRequest (req);
705705 if (!resp.has_subscribe_data_track ()) {
706706 return Result<proto::OwnedDataTrackStream,
707707 SubscribeDataTrackError>::failure (SubscribeDataTrackError{
0 commit comments