Index: mojo/public/cpp/bindings/lib/validation_util.cc |
diff --git a/mojo/public/cpp/bindings/lib/validation_util.cc b/mojo/public/cpp/bindings/lib/validation_util.cc |
index 3051c1c2368eb9d3a213dec457823c725e6dd00b..adfba70b57ec36ec0c961b95278cf113a6ec4915 100644 |
--- a/mojo/public/cpp/bindings/lib/validation_util.cc |
+++ b/mojo/public/cpp/bindings/lib/validation_util.cc |
@@ -134,5 +134,14 @@ bool ValidateAssociatedInterfaceId(InterfaceId input) { |
return false; |
} |
+bool ValidateNative(const NativePointer& input, BoundsChecker* bounds_checker) { |
+ if (!ValidateEncodedPointer(&input.offset)) { |
+ ReportValidationError(VALIDATION_ERROR_ILLEGAL_POINTER); |
+ return false; |
+ } |
+ |
+ return true; |
yzshen1
2015/12/15 21:20:27
I think here we need to use the Validate() of Arra
Ken Rockot(use gerrit already)
2015/12/15 23:31:07
Done.
|
+} |
+ |
} // namespace internal |
} // namespace mojo |