oopr: memcpy memory before deserializing flattenables

To avoid Skia having to care about TOCTOU concerns when deserializing
from shared memory that might be changed underneath it by a malicious
renderer, make a copy of any data that Skia needs to deserialize.

In the future, we could consider microoptimizing these by moving
them into paint data structures to avoid a copy if it turns out to be
too slow.

Change-Id: Ic81fc9667578078331c183e51224d8ce86b56ef5
Reviewed-on: https://chromium-review.googlesource.com/c/1356005
Commit-Queue: enne <enne@chromium.org>
Reviewed-by: Daniel Cheng <dcheng@chromium.org>
Reviewed-by: Antoine Labour <piman@chromium.org>
Reviewed-by: Khushal <khushalsagar@chromium.org>
Cr-Commit-Position: refs/heads/master@{#620472}
13 files changed