Skip to content

Zilla-RS 0.2.2

Choose a tag to compare

@zagg zagg released this 23 Oct 11:45
· 9 commits to master since this release

Zilla-RS 0.2.2 — a bug-fix release. The queue and the folder panes breathe again after a broken transfer.

What's fixed

  • A broken upload no longer poisons the connection. When a STOR was cut short — the peer drops the data channel mid-write, or you put the line in the bin — the client never read the reply the server sends after it closes the channel. That reply then sat in the control stream and got read as the answer to the next command: every folder listing after that failed on a nonsense protocol error (protocole inattendu : PASV : Reply { code: 226, ... }) and fell back to active mode, which timed out. It looked exactly like "no more refresh", and only restarting the service cured it. The transfer channel is now always closed and its reply read, whatever ended the cycle — success, error or cancellation.
  • An interrupted transfer is held accountable. A data channel closed without its reply marks the connection as dirty, so the pool replaces it instead of lending it out for browsing.
  • A listing can no longer sleep forever. The LIST data channel was read without any inactivity bound, while it held the connection mutex: one silent listing froze every other operation on that connection. It is bounded now, like MLSD already was.
  • Dead connections give their slot back. Connections that had already given up the ghost kept their place in the pool, the vector grew with every incident, and the slot stayed filled twice over; the reaper takes them out first now.
  • A stalled line is cut, not waited on. The data channel has an inactivity bound (net.data_timeout, following the 20 s response delay by default) and the queue's watchdog abandons an Active line that has stopped pushing bytes, so the following lines and the listings get their breathing space back.

Verified by

tests/tuyau_casse.rs — a sabotaging mini-FTP server (one that drops the data channel mid-write, one that stops taking bytes at all), driving a real upload and asking the panes to refresh afterwards. One of those scenes still fails when the fix is taken away. The whole suite is 45 tests, green.