@Override
    public boolean ready() throws IOException {
      ensureOpen();
      return true;
    }
Check to make sure that the stream has not been closed
ql/src/java/org/apache/hadoop/hive/ql/udf/xml/UDFXPathUtil.java