Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 9e8b22b9 authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "WM: Don't empty Winscope traces when writing to file."

parents 25a4f6f8 b2476220
Loading
Loading
Loading
Loading
+2 −3
Original line number Diff line number Diff line
@@ -98,9 +98,8 @@ class WindowTraceBuffer {
                ProtoOutputStream proto = new ProtoOutputStream();
                proto.write(MAGIC_NUMBER, MAGIC_NUMBER_VALUE);
                os.write(proto.getBytes());
                while (!mBuffer.isEmpty()) {
                    proto = mBuffer.poll();
                    mBufferUsedSize -= proto.getRawSize();
                for (ProtoOutputStream protoOutputStream : mBuffer) {
                    proto = protoOutputStream;
                    byte[] protoBytes = proto.getBytes();
                    os.write(protoBytes);
                }