You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mina.apache.org by gn...@apache.org on 2015/07/16 13:26:56 UTC

mina-sshd git commit: Fix NPE

Repository: mina-sshd
Updated Branches:
  refs/heads/master ea46a25d2 -> 46f0cb61a


Fix NPE

Project: http://git-wip-us.apache.org/repos/asf/mina-sshd/repo
Commit: http://git-wip-us.apache.org/repos/asf/mina-sshd/commit/46f0cb61
Tree: http://git-wip-us.apache.org/repos/asf/mina-sshd/tree/46f0cb61
Diff: http://git-wip-us.apache.org/repos/asf/mina-sshd/diff/46f0cb61

Branch: refs/heads/master
Commit: 46f0cb61a83ef17112a796759c0386b4ee00073a
Parents: ea46a25
Author: Guillaume Nodet <gn...@apache.org>
Authored: Thu Jul 16 13:26:43 2015 +0200
Committer: Guillaume Nodet <gn...@apache.org>
Committed: Thu Jul 16 13:26:43 2015 +0200

----------------------------------------------------------------------
 .../sshd/client/subsystem/sftp/SftpFileSystemProvider.java      | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/mina-sshd/blob/46f0cb61/sshd-core/src/main/java/org/apache/sshd/client/subsystem/sftp/SftpFileSystemProvider.java
----------------------------------------------------------------------
diff --git a/sshd-core/src/main/java/org/apache/sshd/client/subsystem/sftp/SftpFileSystemProvider.java b/sshd-core/src/main/java/org/apache/sshd/client/subsystem/sftp/SftpFileSystemProvider.java
index e041cf4..85324e2 100644
--- a/sshd-core/src/main/java/org/apache/sshd/client/subsystem/sftp/SftpFileSystemProvider.java
+++ b/sshd-core/src/main/java/org/apache/sshd/client/subsystem/sftp/SftpFileSystemProvider.java
@@ -318,11 +318,10 @@ public class SftpFileSystemProvider extends FileSystemProvider {
             @Override
             public Iterator<Path> iterator() {
                 return new Iterator<Path>() {
-                    private boolean dotIgnored, dotdotIgnored;
-                    private SftpClient.DirEntry curEntry = nextEntry();
-
                     @SuppressWarnings("synthetic-access")
                     private final Iterator<SftpClient.DirEntry> it = iter.iterator();
+                    private boolean dotIgnored, dotdotIgnored;
+                    private SftpClient.DirEntry curEntry = nextEntry();
 
                     @Override
                     public boolean hasNext() {