Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1849)

Unified Diff: mojo/public/cpp/bindings/lib/pipe_control_message_proxy.cc

Issue 2064903002: Mojo: Report bindings validation errors via MojoNotifyBadMessage (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: . Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: mojo/public/cpp/bindings/lib/pipe_control_message_proxy.cc
diff --git a/mojo/public/cpp/bindings/lib/pipe_control_message_proxy.cc b/mojo/public/cpp/bindings/lib/pipe_control_message_proxy.cc
index a7f340fb701d4deeba0dcd4344be7899409012cf..acbf5a2ee1b6d98e6e26f19856014675d836f606 100644
--- a/mojo/public/cpp/bindings/lib/pipe_control_message_proxy.cc
+++ b/mojo/public/cpp/bindings/lib/pipe_control_message_proxy.cc
@@ -9,6 +9,7 @@
#include "base/compiler_specific.h"
#include "base/logging.h"
+#include "base/macros.h"
#include "mojo/public/cpp/bindings/lib/message_builder.h"
#include "mojo/public/cpp/bindings/lib/serialization.h"
#include "mojo/public/cpp/bindings/message.h"
@@ -35,10 +36,9 @@ void SendRunOrClosePipeMessage(MessageReceiver* receiver,
params_ptr, builder.buffer(), &params, context);
params->EncodePointers();
builder.message()->set_interface_id(kInvalidInterfaceId);
- bool ok = receiver->Accept(builder.message());
- // This return value may be ignored as !ok implies the underlying message pipe
- // has encountered an error, which will be visible through other means.
- ALLOW_UNUSED_LOCAL(ok);
+ // This return value may be ignored as failure implies the underlying message
+ // pipe has encountered an error, which will be visible through other means.
+ ignore_result(receiver->Accept(builder.message()));
}
} // namespace

Powered by Google App Engine
This is Rietveld 408576698