Merge "Fixed octal printing of bytearrays"

pull/91/head
Max Cai 10 years ago committed by Gerrit Code Review
commit 04f70ef5c7
  1. 2
      java/src/main/java/com/google/protobuf/nano/MessageNanoPrinter.java

@ -249,7 +249,7 @@ public final class MessageNanoPrinter {
} else if (ch >= 32 && ch < 127) { } else if (ch >= 32 && ch < 127) {
builder.append((char) ch); builder.append((char) ch);
} else { } else {
builder.append(String.format("\\%03o", ch)); builder.append(String.format("\\%03o", ch && 0xff));
} }
} }
builder.append('"'); builder.append('"');

Loading…
Cancel
Save