简体   繁体   中英

SharpSSH's Scp object can't copy files bigger than 2GB

Whenever I try to copy a file that's bigger than 2GB, I get an array index out of bounds exception in the Get method:

Scp myScp = new Scp("remotehost", "joe", "mypassword");
myScp.OnTransferProgress += new FileTransferEvent(scpProg);
myScp.Connect(22);
myScp.Get("/home/joe/bigfile.bin", "/tmp/bigfile.bin");
myScp.Close();

...which I solved by patching SharpSSH replacing int with Int64 in strategic places. Here's the patch .

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM