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

Commit 59be1180 authored by Zhi Dou's avatar Zhi Dou
Browse files

new buffer reader for buffer read

This change will create new buffer reader when the code needs to read
the buffer read. Previously there is only new buffer reader in the
class, so if there are multiple threads call the get method in
PackageTable, then these threads will modify the buffer position can
cause a race condition.

This change will create new buffer reader when the code needs to read
the buffer in the method. so each thread will have its own instance of
the reader, and the reader will maintain the position.

Test: atest aconfig_storage_file.test.java
Bug: 397997135
Flag: EXAMPT refactor
Change-Id: I31ac2ab661ec1711f817068917915ae63e1e8dd4
parent 2b5a4066
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment