[Android] Permit getrusage.

The change in dd690a72b48c558f1dce4debc475495f83c9fac3 was supposed to
allow getrusage for RUSAGE_SELF and RUSAGE_THREAD. But the
RestrictGetrusage() result is only used when building for sanitizers.
This explicitly adds the allowance to the Android baseline policy.

Also add a test to verify this.

Bug: 826289, 812250
Cq-Include-Trybots: master.tryserver.chromium.android:android_arm64_dbg_recipe;master.tryserver.chromium.android:android_compile_x64_dbg;master.tryserver.chromium.android:android_compile_x86_dbg
Change-Id: I1c6f4a90a78ca6b3ca987baf8767c26f38b3ef81
Reviewed-on: https://chromium-review.googlesource.com/984436
Reviewed-by: Jorge Lucangeli Obes <jorgelo@chromium.org>
Commit-Queue: Robert Sesek <rsesek@chromium.org>
Cr-Original-Commit-Position: refs/heads/master@{#546811}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: a64d57370ed3b94b0b9844c89a9973f1cfe7cf2e
3 files changed
tree: ad5928e3380ff80101fbc7997d0b915b25cd6be1
  1. linux/
  2. mac/
  3. win/
  4. BUILD.gn
  5. features.gni
  6. ipc.dict
  7. OWNERS
  8. sandbox_export.h