You are viewing a plain text version of this content. The canonical link for it is here.
Posted to common-commits@hadoop.apache.org by st...@apache.org on 2022/05/30 16:35:02 UTC
[hadoop] branch branch-3.3 updated: HADOOP-18238. Fix reentrancy check in SFTPFileSystem.close() (#4330)
This is an automated email from the ASF dual-hosted git repository.
stevel pushed a commit to branch branch-3.3
in repository https://gitbox.apache.org/repos/asf/hadoop.git
The following commit(s) were added to refs/heads/branch-3.3 by this push:
new de4c9757103 HADOOP-18238. Fix reentrancy check in SFTPFileSystem.close() (#4330)
de4c9757103 is described below
commit de4c975710344f94810ec17652e96e9c5c1d86b2
Author: Ashutosh Gupta <as...@st.niituniversity.in>
AuthorDate: Mon May 30 17:34:06 2022 +0100
HADOOP-18238. Fix reentrancy check in SFTPFileSystem.close() (#4330)
Contributed by Ashutosh Gupta
Change-Id: I2742675add74259a93b3762a80c7ab5ee6d08c37
---
.../src/main/java/org/apache/hadoop/fs/sftp/SFTPFileSystem.java | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/sftp/SFTPFileSystem.java b/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/sftp/SFTPFileSystem.java
index 297ec048e50..abfd24d68d0 100644
--- a/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/sftp/SFTPFileSystem.java
+++ b/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/sftp/SFTPFileSystem.java
@@ -709,11 +709,11 @@ public class SFTPFileSystem extends FileSystem {
@Override
public void close() throws IOException {
- if (closed.getAndSet(true)) {
- return;
- }
try {
super.close();
+ if (closed.getAndSet(true)) {
+ return;
+ }
} finally {
if (connectionPool != null) {
connectionPool.shutdown();
---------------------------------------------------------------------
To unsubscribe, e-mail: common-commits-unsubscribe@hadoop.apache.org
For additional commands, e-mail: common-commits-help@hadoop.apache.org