Skip to content

Commit

Permalink
Cleanup remaining payload channel references
Browse files Browse the repository at this point in the history
  • Loading branch information
jmillan committed Feb 2, 2024
1 parent 01075b1 commit d7578e5
Show file tree
Hide file tree
Showing 7 changed files with 2 additions and 15 deletions.
2 changes: 0 additions & 2 deletions rust/src/worker/utils.rs
Original file line number Diff line number Diff line change
Expand Up @@ -80,8 +80,6 @@ where
version.as_ptr(),
0,
0,
0,
0,
channel_read_fn,
channel_read_ctx,
channel_write_fn,
Expand Down
3 changes: 1 addition & 2 deletions worker/include/Channel/ChannelNotifier.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ namespace Channel
FBS::Notification::Body type,
flatbuffers::Offset<Body>& body)
{
auto& builder = ChannelNotifier::bufferBuilder;
auto& builder = this->bufferBuilder;
auto notification = FBS::Notification::CreateNotificationDirect(
builder, targetId.c_str(), event, type, body.Union());

Expand All @@ -50,7 +50,6 @@ namespace Channel
this->channel->Send(builder.GetBufferPointer(), builder.GetSize());
builder.Reset();
}
void Emit(const FBS::Notification::Notification& notification);

private:
// Passed by argument.
Expand Down
2 changes: 0 additions & 2 deletions worker/include/lib.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,6 @@ extern "C" int mediasoup_worker_run(
const char* version,
int consumerChannelFd,
int producerChannelFd,
int payloadConsumeChannelFd,
int payloadProduceChannelFd,
ChannelReadFn channelReadFn,
ChannelReadCtx channelReadCtx,
ChannelWriteFn channelWriteFn,
Expand Down
2 changes: 1 addition & 1 deletion worker/src/Channel/ChannelSocket.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ namespace Channel
return;
}

SendImpl(reinterpret_cast<const uint8_t*>(data), dataLen);
SendImpl(data, dataLen);
}

void ChannelSocket::SendLog(const char* data, uint32_t dataLen)
Expand Down
2 changes: 0 additions & 2 deletions worker/src/lib.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,6 @@ extern "C" int mediasoup_worker_run(
const char* version,
int consumerChannelFd,
int producerChannelFd,
int /*payloadConsumeChannelFd*/,
int /*payloadProduceChannelFd*/,
ChannelReadFn channelReadFn,
ChannelReadCtx channelReadCtx,
ChannelWriteFn channelWriteFn,
Expand Down
2 changes: 0 additions & 2 deletions worker/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,6 @@ extern "C" {
version: *const c_char,
consumer_channel_fd: c_int,
producer_channel_fd: c_int,
payload_consumer_channel_fd: c_int,
payload_producer_channel_fd: c_int,
channel_read_fn: ChannelReadFn,
channel_read_ctx: ChannelReadCtx,
channel_write_fn: ChannelWriteFn,
Expand Down
4 changes: 0 additions & 4 deletions worker/src/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,6 @@

static constexpr int ConsumerChannelFd{ 3 };
static constexpr int ProducerChannelFd{ 4 };
static constexpr int PayloadConsumerChannelFd{ 5 };
static constexpr int PayloadProducerChannelFd{ 6 };

int main(int argc, char* argv[])
{
Expand All @@ -30,8 +28,6 @@ int main(int argc, char* argv[])
version.c_str(),
ConsumerChannelFd,
ProducerChannelFd,
PayloadConsumerChannelFd,
PayloadProducerChannelFd,
nullptr,
nullptr,
nullptr,
Expand Down

0 comments on commit d7578e5

Please sign in to comment.