read
Read from a descriptor, without using and updating the descriptor's offset.
This function returns a list of bytes containing the data that was read, along with a bool which, when true, indicates that the end of the file was reached. The returned list will contain up to length
bytes; it may return fewer than requested, if the end of the file is reached or if the I/O operation is interrupted.
Note: This is similar to pread
in POSIX.