Bug 1354

Summary: slight problems with sftp client
Product: Portable OpenSSH Reporter: Tomas Mraz <t8m>
Component: sftpAssignee: Assigned to nobody <unassigned-bugs>
Status: CLOSED FIXED    
Severity: normal CC: djm
Priority: P2    
Version: 4.6p1   
Hardware: Other   
OS: Linux   
Bug Depends on:    
Bug Blocks: 1353    
Attachments:
Description Flags
Patch for draining the acks properly
none
Patch for the second problem none

Description Tomas Mraz 2007-08-14 19:42:55 AEST
We've found 2 slight problems with sftp client.

1. when uploading files to an almost full disk on remote system the sftp client aborts prematurely with ID mismatch error. This happens because of not draining acks from the remote side properly.

2. if the above problem is fixed this problem appears - when uploading multiple files with wildcard match in the same situation it will not abort the command on first failed transfer but it tries to transfer the remaining matching files.
Comment 1 Tomas Mraz 2007-08-14 19:45:31 AEST
Created attachment 1340 [details]
Patch for draining the acks properly

This is the patch for the first problem.
Comment 2 Tomas Mraz 2007-08-14 19:55:32 AEST
Created attachment 1341 [details]
Patch for the second problem

This patch fixes the second problem. On the other hand it is debatable whether the second problem is a real bug or rather a feature.
Comment 3 Damien Miller 2007-11-03 15:51:48 AEDT
I agree about the 2nd not being a bug for interactive use, but perhaps we should allow early termination of the upload when we are in strict error more (e.g. batchmode).
Comment 4 Damien Miller 2008-01-22 06:24:56 AEDT
1st patch applied - thanks.

I'm not going to change the behaviour of sftp when one file in the middle of a up/download batch fails. Continuing the transfer is the most friendly thing to do for interactive use, and I don't want the commands to have different semantics when batchmode is active.
Comment 5 Damien Miller 2008-03-31 15:21:04 AEDT
Fix shipped in 4.9/4.9p1 release.