From f9b27f5424cb857406a60a2259052dfff1d76439 Mon Sep 17 00:00:00 2001 From: bnewbold Date: Sun, 29 May 2016 21:08:06 -0400 Subject: disable set_len() for now --- src/common.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/common.rs b/src/common.rs index afdfe06..e68bae6 100644 --- a/src/common.rs +++ b/src/common.rs @@ -102,7 +102,8 @@ pub fn sink_files(stream: &mut UtpStream, file_path: &str, recursive: bool) { let flen: usize = line[1].parse::().unwrap(); let fpath = Path::new(line[2]); - f.set_len(flen as u64).unwrap(); + // TODO: I've disabled set_len; is this best practice? scp doesn't do it. + //f.set_len(flen as u64).unwrap(); fs::set_permissions(file_path, PermissionsExt::from_mode(fmode)).unwrap(); let mut received: usize = 0; -- cgit v1.2.3