Close file descriptors of ProfilerInfo
When using "am start --start-profiler" command, am doesn't close instances of related ParcelFileDescriptor of the profiler file path, but relies on garbage collection, so at the system level the file kept open for longer than it is needed. In a result, some processes that monitors the file close event using unix inotify_add_watch method would wait 20~30 Seconds. This change closes file descriptors after passing it to ActivityThread process, which is similar to what "am profile start" does. Bug: b/73891014 Test: tested manually by flashing into Pixel XL device. Change-Id: I5b63b96335fdaf86f0cd0caec2c53c32c0e41d72 (cherry picked from commit b101e4b0)
Loading
Please register or sign in to comment