try {
io.getOpenFile().checkReadable(context.getRuntime());
} catch (PipeException pe) {
throw runtime.newErrnoEPIPEError();
} catch (IOException ex) {
throw runtime.newIOErrorFromException(ex);
} catch (BadDescriptorException ex) {
throw runtime.newErrnoEBADFError();
} catch (InvalidValueException e) {
throw runtime.newErrnoEINVALError();
}