HADOOP-11101. How about inputstream close statement from catch block to finally block in FileContext#copy() ( Contributed by skrho )
(cherry picked from commit dff95f7af8
)
This commit is contained in:
parent
83926b3c57
commit
1e097ba429
|
@ -206,6 +206,9 @@ Release 2.6.0 - UNRELEASED
|
|||
|
||||
HADOOP-11009. Add Timestamp Preservation to DistCp (Gary Steelman via aw)
|
||||
|
||||
HADOOP-11101. How about inputstream close statement from catch block to
|
||||
finally block in FileContext#copy() ( skrho via vinayakumarb )
|
||||
|
||||
OPTIMIZATIONS
|
||||
|
||||
HADOOP-10838. Byte array native checksumming. (James Thomas via todd)
|
||||
|
|
|
@ -2035,10 +2035,9 @@ public final class FileContext {
|
|||
EnumSet.of(CreateFlag.CREATE);
|
||||
out = create(qDst, createFlag);
|
||||
IOUtils.copyBytes(in, out, conf, true);
|
||||
} catch (IOException e) {
|
||||
} finally {
|
||||
IOUtils.closeStream(out);
|
||||
IOUtils.closeStream(in);
|
||||
throw e;
|
||||
}
|
||||
}
|
||||
if (deleteSource) {
|
||||
|
|
Loading…
Reference in New Issue