summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Treehugger Robot <treehugger-gerrit@google.com> 2020-07-31 21:53:45 +0000
committer Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com> 2020-07-31 21:53:45 +0000
commit9185ac265bfb1b1a506db16cded2d4469f68fef0 (patch)
treeb3d501ce101aa7e87091c661ce75f35ace191d25
parent36145d474034eacc496a12cbf4edf643cc47dba3 (diff)
parentd82657834adfdaf4a127ee4fcadd64273584ef40 (diff)
Merge "Update language to comply with Android's inclusive language guidance" am: 1d2417fa16 am: 436fe675e1 am: 37be2eefe9 am: d82657834a
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1383976 Change-Id: I33f3ef3a15f0b15c4397dee73c2aeb6c3a29061d
-rw-r--r--core/java/android/util/proto/ProtoInputStream.java6
-rw-r--r--core/java/android/util/proto/ProtoOutputStream.java8
2 files changed, 7 insertions, 7 deletions
diff --git a/core/java/android/util/proto/ProtoInputStream.java b/core/java/android/util/proto/ProtoInputStream.java
index cbe3734ce5fa..aa70d07ff787 100644
--- a/core/java/android/util/proto/ProtoInputStream.java
+++ b/core/java/android/util/proto/ProtoInputStream.java
@@ -96,7 +96,7 @@ public final class ProtoInputStream extends ProtoStream {
private byte mState = 0;
/**
- * Keeps track of the currently read nested Objects, for end object sanity checking and debug
+ * Keeps track of the currently read nested Objects, for end object checking and debug
*/
private ArrayList<Long> mExpectedObjectTokenStack = null;
@@ -513,7 +513,7 @@ public final class ProtoInputStream extends ProtoStream {
(int) fieldId, getOffset() + messageSize));
}
- // Sanity check
+ // Validation check
if (mDepth > 0
&& getOffsetFromToken(mExpectedObjectTokenStack.get(mDepth))
> getOffsetFromToken(mExpectedObjectTokenStack.get(mDepth - 1))) {
@@ -536,7 +536,7 @@ public final class ProtoInputStream extends ProtoStream {
* @param token - token
*/
public void end(long token) {
- // Sanity check to make sure user is keeping track of their embedded messages
+ // Make sure user is keeping track of their embedded messages
if (mExpectedObjectTokenStack.get(mDepth) != token) {
throw new ProtoParseException(
"end token " + token + " does not match current message token "
diff --git a/core/java/android/util/proto/ProtoOutputStream.java b/core/java/android/util/proto/ProtoOutputStream.java
index 5fcd38e2fd9c..afca4ab2c741 100644
--- a/core/java/android/util/proto/ProtoOutputStream.java
+++ b/core/java/android/util/proto/ProtoOutputStream.java
@@ -59,10 +59,10 @@ import java.io.UnsupportedEncodingException;
* cache the size, and then write the size-prefixed buffers.
*
* We are trying to avoid too much generated code here, but this class still
- * needs to have a somewhat sane API. We can't have the multiple passes be
- * done by the calling code. In addition, we want to avoid the memory high
- * water mark of duplicating all of the values into the traditional in-memory
- * Message objects. We need to find another way.
+ * needs to have API. We can't have the multiple passes be done by the
+ * calling code. In addition, we want to avoid the memory high water mark
+ * of duplicating all of the values into the traditional in-memory Message
+ * objects. We need to find another way.
*
* So what we do here is to let the calling code write the data into a
* byte[] (actually a collection of them wrapped in the EncodedBuffer class),