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

Side by Side Diff: mojo/public/cpp/bindings/lib/validation_errors.cc

Issue 2660733002: Mojo C++ bindings: introduce an optional array to store transferred interface IDs in messages. (Closed)
Patch Set: . Created 3 years, 10 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 unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "mojo/public/cpp/bindings/lib/validation_errors.h" 5 #include "mojo/public/cpp/bindings/lib/validation_errors.h"
6 6
7 #include "base/strings/stringprintf.h" 7 #include "base/strings/stringprintf.h"
8 #include "mojo/public/cpp/bindings/message.h" 8 #include "mojo/public/cpp/bindings/message.h"
9 9
10 namespace mojo { 10 namespace mojo {
(...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after
91 context->description().data(), 91 context->description().data(),
92 ValidationErrorToString(error))); 92 ValidationErrorToString(error)));
93 } 93 }
94 } 94 }
95 } 95 }
96 96
97 void ReportValidationErrorForMessage( 97 void ReportValidationErrorForMessage(
98 mojo::Message* message, 98 mojo::Message* message,
99 ValidationError error, 99 ValidationError error,
100 const char* description) { 100 const char* description) {
101 ValidationContext validation_context( 101 ValidationContext validation_context(nullptr, 0, 0, 0, message, description);
102 message->data(), message->data_num_bytes(),
103 message->handles()->size(), message,
104 description);
105 ReportValidationError(&validation_context, error); 102 ReportValidationError(&validation_context, error);
106 } 103 }
107 104
108 ScopedSuppressValidationErrorLoggingForTests 105 ScopedSuppressValidationErrorLoggingForTests
109 ::ScopedSuppressValidationErrorLoggingForTests() 106 ::ScopedSuppressValidationErrorLoggingForTests()
110 : was_suppressed_(g_suppress_logging) { 107 : was_suppressed_(g_suppress_logging) {
111 g_suppress_logging = true; 108 g_suppress_logging = true;
112 } 109 }
113 110
114 ScopedSuppressValidationErrorLoggingForTests 111 ScopedSuppressValidationErrorLoggingForTests
(...skipping 29 matching lines...) Expand all
144 } 141 }
145 142
146 SerializationWarningObserverForTesting:: 143 SerializationWarningObserverForTesting::
147 ~SerializationWarningObserverForTesting() { 144 ~SerializationWarningObserverForTesting() {
148 DCHECK(g_serialization_warning_observer == this); 145 DCHECK(g_serialization_warning_observer == this);
149 g_serialization_warning_observer = nullptr; 146 g_serialization_warning_observer = nullptr;
150 } 147 }
151 148
152 } // namespace internal 149 } // namespace internal
153 } // namespace mojo 150 } // namespace mojo
OLDNEW
« no previous file with comments | « mojo/public/cpp/bindings/lib/validation_context.cc ('k') | mojo/public/cpp/bindings/lib/validation_util.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698