Merge "Don't delete the new file in openRead()." into rvc-dev am: c74a76863b

Change-Id: Ibf21e027df7db5c2cfd37ac7f19a1ba1383cc531
This commit is contained in:
TreeHugger Robot
2020-05-20 08:03:12 +00:00
committed by Automerger Merge Worker

View File

@@ -227,11 +227,8 @@ public class AtomicFile {
} }
} }
if (mNewName.exists()) { // Don't delete mNewName here - it was okay to call openRead() between startWrite() and
if (!mNewName.delete()) { // finishWrite(), and we have to keep supporting it.
Log.e(LOG_TAG, "Failed to delete outdated new file " + mNewName);
}
}
return new FileInputStream(mBaseName); return new FileInputStream(mBaseName);
} }