Skip to content
  • noel's avatar
    Convert utility process out-of-process file patching IPC to mojo · bfee08c6
    noel authored
    Define interface chrome::mojom::FilePatcher for out-of-process file
    patching. Add the interface to the utility process and expose it to
    to the browser process by mojo policy [1].
    
    ChromeOutOfProcessPatcher: remove PatchHost() helper class, replace
    it with a content::UtilityProcessMojoClient() and use that to start
    and stop the utility process needed for out-of-process file patches
    and to perform out-of-process file patches using mojo calls, rather
    than IPC::Send(). Move the mojo calls to the IO thread to avoid bug
    676960 (mojo does not work from the blocking pool).
    
    Add an in-process browsertest for the ChromeOutOfProcessPatcher (it
    had no tests http://bit.ly/2h8mafX it seems). Copy the golden files
    to random locations (input_file, patch_file) and patch them: checks
    the patched output_file content matches the golden output file. Add
    tests for invalid file inputs to the file patcher. Note all work in
    the tests originates from the blocking pool: bug 676960.
    
    [1] chrome_content_utility_manifest_overlay.json
    
    BUG=597124
    
    Review-Url: https://codereview.chromium.org/2632143002
    Cr-Commit-Position: refs/heads/master@{#445324}
    bfee08c6