(This is a merge of http://go/wvgerrit/13910/ from the Widevine CDM
repository.)
DeviceFiles has a lot of repeated code whenever it needs to check for
file existence or remove a file. When reading and writing files, it
has wrappers that handle this repeated burden. This change adds
wrappers for the other functionality used by DeviceFiles as well, to
reduce duplication.
Change-Id: If959b504672c1b907346d28f31648d8028de8bdf