Signed-off-by: starainrt <i@b612.me>
master v0.0.1
兔子 4 years ago
parent be040542bb
commit bab26a32ba

@ -33,7 +33,7 @@ func SftpTransferOut(localFilePath, remotePath string, sftpClient *sftp.Client)
} }
defer dstFile.Close() defer dstFile.Close()
for { for {
buf := make([]byte, 1024) buf := make([]byte, 1048576)
n, err := srcFile.Read(buf) n, err := srcFile.Read(buf)
dstFile.Write(buf[:n]) dstFile.Write(buf[:n])
if err == io.EOF { if err == io.EOF {

Loading…
Cancel
Save