title: Error during scp transfer from windows to windows (ch.ethz.ssh2.SCPClient.put)
body: <p>I am using package ch.ethz.ssh2 which has a class SCPClient to transfer files from one windows machine to another. The remote windiws machine has been installed with cygwin 2.874 (64bit) with the packages: openssl and openssh and other prerequisites.</p>
  <p>Below is my java code for file transfer:</p>
  <pre><code>private void copyRecursively(File local, String remotePath) throws Exception {
      String name = local.getName();
      if (&lt;iHaveSomeCondHereToExit&gt;) {
          if (local.isDirectory()) {
              String newPath = remotePath + &quot;/&quot; + name;
              createRemoteDir(newPath);
              File[] files = local.listFiles();
              for (File f : files) {
                  copyRecursively(f, newPath);
              }
          } else {
              
                  String localPath = local.getPath();
                  Log.info(&quot;copy file from &quot; + localPath + &quot; to &quot;
                          + remotePath);
                  osSupport.uploadFile(localPath, remotePath);
              
          }
      } 
  }
  </code></pre>
  <p>I have a osSupport.java file which has uploadFile function as below:</p>
  <pre><code>public void uploadFile(String localFile, String targetPath)
              throws Exception {
          getScpClientObj().put(localFile, targetPath);
      }
  </code></pre>
  <p>I am getting error as</p>
  <blockquote>
  <p>java.io.IOException: Error during scp transfer</p>
  <p>at ch.ethz.ssh2.SCPClient.put(SCPClient.java:575) ~[ganymed-ssh2-build210.jar:na]</p>
  </blockquote>
  <p>Please help me with this issue.
  The same code works when i used the remote machine as linux server.</p>