Use unique error value in broker_process_unitetest.cc
Distinguish between the permission errors the broker process fabricates vs. organically ocurring EPERM from a syscall. Use block-scope rather than unique_ptrs to force broker destruction. Fix a dubious use of ScopedFD(). ScopeFD's only legal bad FD value is -1, which co-incidentally happens to be -EPERM. So don't apply this where we know the file is invalid, since other negative values cause a CHECK(). Convert some ASSERTS to EXPECTS, to avoid crashes. Change-Id: I822e15e1ff386687627ba27c8f9fff158c10f316 Reviewed-on: https://chromium-review.googlesource.com/797919 Commit-Queue: Tom Sepez <tsepez@chromium.org> Reviewed-by:Robert Sesek <rsesek@chromium.org> Cr-Commit-Position: refs/heads/master@{#521051}
Showing
This diff is collapsed.
Please register or sign in to comment