Skip to content

Commit

Permalink
pw_bluetooth_proxy: Fix compilation errors
Browse files Browse the repository at this point in the history
Use PW_MODIFY_DIAGNOSTICS instead of raw preprocessor directives.
Update invocation of ProxyHost constructor in size_report to pass
recently added `le_acl_credits_to_reserve` argument.

Change-Id: I69892fd75712e3816ccf09f5b70cd934a9f6a4fe
Reviewed-on: https://pigweed-review.googlesource.com/c/pigweed/pigweed/+/213733
Reviewed-by: David Rees <drees@google.com>
Commit-Queue: Ali Saeed <saeedali@google.com>
Lint: Lint 🤖 <android-build-ayeaye@system.gserviceaccount.com>
  • Loading branch information
acsaeed authored and CQ Bot Account committed Jun 4, 2024
1 parent 5f16474 commit dea891a
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
6 changes: 3 additions & 3 deletions pw_bluetooth_proxy/proxy_host.cc
Original file line number Diff line number Diff line change
Expand Up @@ -61,8 +61,8 @@ void ProxyHost::ProcessH4HciFromController(H4HciPacket h4_packet) {
return;
}

#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wswitch-enum"
PW_MODIFY_DIAGNOSTICS_PUSH();
PW_MODIFY_DIAGNOSTIC(ignored, "-Wswitch-enum");
switch (command_complete_event.command_opcode_enum().Read()) {
case emboss::OpCode::LE_READ_BUFFER_SIZE_V1: {
auto read_event =
Expand Down Expand Up @@ -94,7 +94,7 @@ void ProxyHost::ProcessH4HciFromController(H4HciPacket h4_packet) {
// Nothing to process
break;
}
#pragma clang diagnostic pop
PW_MODIFY_DIAGNOSTICS_POP();
}

void ProxyHost::HandleH4HciFromController(H4HciPacket h4_packet) {
Expand Down
3 changes: 2 additions & 1 deletion pw_bluetooth_proxy/size_report/use_passthrough_proxy.cc
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,8 @@ void UsePassthroughProxy() {
([]([[maybe_unused]] H4HciPacket packet) {}));

ProxyHost proxy = ProxyHost(std::move(containerSendToHostFn),
std::move(containerSendToControllerFn));
std::move(containerSendToControllerFn),
0);

proxy.HandleH4HciFromHost(h4_span_from_host);

Expand Down

0 comments on commit dea891a

Please sign in to comment.