parquet-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From b...@apache.org
Subject incubator-parquet-mr git commit: PARQUET-145 InternalParquetRecordReader.close() should not throw an exception if initialization has failed
Date Thu, 11 Dec 2014 22:01:39 GMT
Repository: incubator-parquet-mr
Updated Branches:
  refs/heads/master ccc29e4dd -> b7a82a918


PARQUET-145 InternalParquetRecordReader.close() should not throw an exception if initialization
has failed

PARQUET-145 InternalParquetRecordReader.close() should not throw an exception if initialization
has failed

Author: Wolfgang Hoschek <whoschek@cloudera.com>

Closes #93 from whoschek/PARQUET-145-3 and squashes the following commits:

52a6acb [Wolfgang Hoschek] PARQUET-145 InternalParquetRecordReader.close() should not throw
an exception if initialization has failed


Project: http://git-wip-us.apache.org/repos/asf/incubator-parquet-mr/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-parquet-mr/commit/b7a82a91
Tree: http://git-wip-us.apache.org/repos/asf/incubator-parquet-mr/tree/b7a82a91
Diff: http://git-wip-us.apache.org/repos/asf/incubator-parquet-mr/diff/b7a82a91

Branch: refs/heads/master
Commit: b7a82a918f0a595a96047f7eef2672fd95d5626c
Parents: ccc29e4
Author: Wolfgang Hoschek <whoschek@cloudera.com>
Authored: Thu Dec 11 14:01:27 2014 -0800
Committer: Ryan Blue <blue@apache.org>
Committed: Thu Dec 11 14:01:27 2014 -0800

----------------------------------------------------------------------
 .../main/java/parquet/hadoop/InternalParquetRecordReader.java    | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-parquet-mr/blob/b7a82a91/parquet-hadoop/src/main/java/parquet/hadoop/InternalParquetRecordReader.java
----------------------------------------------------------------------
diff --git a/parquet-hadoop/src/main/java/parquet/hadoop/InternalParquetRecordReader.java
b/parquet-hadoop/src/main/java/parquet/hadoop/InternalParquetRecordReader.java
index 5a9b019..9a0d5d0 100644
--- a/parquet-hadoop/src/main/java/parquet/hadoop/InternalParquetRecordReader.java
+++ b/parquet-hadoop/src/main/java/parquet/hadoop/InternalParquetRecordReader.java
@@ -131,7 +131,9 @@ class InternalParquetRecordReader<T> {
   }
 
   public void close() throws IOException {
-    reader.close();
+    if (reader != null) {
+      reader.close();
+    }
   }
 
   public Void getCurrentKey() throws IOException, InterruptedException {


Mime
View raw message