Quellcode durchsuchen

HADOOP-10690. Lack of synchronization on access to InputStream in NativeAzureFileSystem#NativeAzureFsInputStream#close(). Contributed by Chen He.

git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/trunk@1604236 13f79535-47bb-0310-9956-ffa450edef68
Chris Nauroth vor 11 Jahren
Ursprung
Commit
61bf9f7799

+ 4 - 0
hadoop-common-project/hadoop-common/CHANGES.txt

@@ -588,6 +588,10 @@ Release 2.5.0 - UNRELEASED
     HADOOP-10689. InputStream is not closed in
     AzureNativeFileSystemStore#retrieve(). (Chen He via cnauroth)
 
+    HADOOP-10690. Lack of synchronization on access to InputStream in
+    NativeAzureFileSystem#NativeAzureFsInputStream#close().
+    (Chen He via cnauroth)
+
   BREAKDOWN OF HADOOP-10514 SUBTASKS AND RELATED JIRAS
 
     HADOOP-10520. Extended attributes definition and FileSystem APIs for

+ 1 - 1
hadoop-tools/hadoop-azure/src/main/java/org/apache/hadoop/fs/azure/NativeAzureFileSystem.java

@@ -193,7 +193,7 @@ public class NativeAzureFileSystem extends FileSystem {
     }
 
     @Override
-    public void close() throws IOException {
+    public synchronized void close() throws IOException {
       in.close();
     }