Commit dcd2189b authored by petrcermak's avatar petrcermak Committed by Commit bot

Fix LibInfo unmarshalling exception in Linker

This patch fixes the Chromium Android Linker bug which causes a
RuntimeException when LibInfos are unmarshalled from the shared RELRO
Bundle in renderer process. The problem was caused by an ABI mismatch
between ParcelFileDescriptor.writeToParcel() and
Parcel.readFileDescriptor() (b/19451018).

BUG=348621, 382485

Review URL: https://codereview.chromium.org/941913003

Cr-Commit-Position: refs/heads/master@{#317318}
parent 452556f2
......@@ -1039,7 +1039,7 @@ public class Linker {
mLoadSize = in.readLong();
mRelroStart = in.readLong();
mRelroSize = in.readLong();
ParcelFileDescriptor fd = in.readFileDescriptor();
ParcelFileDescriptor fd = ParcelFileDescriptor.CREATOR.createFromParcel(in);
// If CreateSharedRelro fails, the OS file descriptor will be -1 and |fd| will be null.
mRelroFd = (fd == null) ? -1 : fd.detachFd();
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment