SVN 1.7: status through command line: fix NPE
authorirengrig <Irina.Chernushina@jetbrains.com>
Wed, 1 Feb 2012 14:37:32 +0000 (18:37 +0400)
committerirengrig <Irina.Chernushina@jetbrains.com>
Wed, 1 Feb 2012 14:37:32 +0000 (18:37 +0400)
plugins/svn4idea/src/org/jetbrains/idea/svn17/commandLine/SvnStatusHandler.java

index 853f8bf1d28c6e6f94e7a3cc3f4bf53e7e0b8914..3ff4c027b40c3b2bf9bbcbf34ce25f6c61a180f5 100644 (file)
@@ -95,11 +95,12 @@ public class SvnStatusHandler extends DefaultHandler {
   }
 
   private void newPending(final Convertor<File, SVNInfo> infoGetter) {
   }
 
   private void newPending(final Convertor<File, SVNInfo> infoGetter) {
-    myPending = new PortableStatus();
-    myPending.setInfoGetter(new Getter<SVNInfo>() {
+    final PortableStatus status = new PortableStatus();
+    myPending = status;
+    status.setInfoGetter(new Getter<SVNInfo>() {
       @Override
       public SVNInfo get() {
       @Override
       public SVNInfo get() {
-        return infoGetter.convert(myPending.getFile());
+        return infoGetter.convert(status.getFile());
       }
     });
   }
       }
     });
   }