mirror of
https://gitee.com/chinabugotech/hutool.git
synced 2025-07-21 15:09:48 +08:00
修复StampedCache类get方法并发问题(issue#IBCIQG@Gitee)
This commit is contained in:
@@ -201,7 +201,7 @@ public class JschSftp extends AbstractFtp {
|
||||
* @since 4.1.14
|
||||
*/
|
||||
public ChannelSftp getClient() {
|
||||
if (false == this.channel.isConnected()) {
|
||||
if (!this.channel.isConnected()) {
|
||||
init();
|
||||
}
|
||||
return this.channel;
|
||||
|
@@ -89,7 +89,7 @@ public class JschUtil {
|
||||
public static Channel createChannel(final Session session, final ChannelType channelType, final long timeout) {
|
||||
final Channel channel;
|
||||
try {
|
||||
if (false == session.isConnected()) {
|
||||
if (!session.isConnected()) {
|
||||
session.connect((int) timeout);
|
||||
}
|
||||
channel = session.openChannel(channelType.getValue());
|
||||
|
Reference in New Issue
Block a user