summaryrefslogtreecommitdiff
path: root/tools/aapt2/java/JavaClassGenerator_test.cpp
diff options
context:
space:
mode:
authorMartijn Coenen <maco@google.com>2020-03-11 13:38:19 +0100
committerMartijn Coenen <maco@google.com>2020-03-11 13:40:48 +0100
commit13885b73dd26bb04884b315534b0da9d82253f8e (patch)
tree8ee3f93b4f0b2263c9fce51242ca3a69642961b2 /tools/aapt2/java/JavaClassGenerator_test.cpp
parenta8c6c8b1f6595cfc68ed0ae3e2ba4bd0de50cce8 (diff)
Use REPLACE_EXISTING for rename(2) workaround.
We implement a workaround for Os.rename() failing with EXDEV, by using Files.move() instead. However, since we didn't pass in REPLACE_EXISTING as an option, Files.move() would fail if the destination file already existed. Since the semantics of rename(2) are to replace a file if it already exists, the work-around should do the same; so pass the flag. Also, log if the workaround throws an exception; that would have made this easier to debug. Bug: 151078664 Test: atest com.android.tests.fused.host.FuseDaemonHostTest#testRenameAndReplaceFile Change-Id: Ie84e89f857c2cc71e3b373db2032f700d066cf6b
Diffstat (limited to 'tools/aapt2/java/JavaClassGenerator_test.cpp')
0 files changed, 0 insertions, 0 deletions