Add fsync(2) and fdatasync(2).
Interesting parts to this change:
* first BlockGuard support (and general delegation support).
* first rethrowing of ErrnoException as IOException.
* switching FileChannelImpl from int to FileDescriptor.
The special case in FileDescriptor.sync has been removed. Testing with the RI
showed that it doesn't treat syncing a FileDescriptor that corresponds to a
socket as a special case --- it throws SyncFailedException just like normal.
Bug: 3107501
Change-Id: I99faf120bd802aec0397a79772ed38c5e1542fed
22 files changed