Chunk server: client state machine: change discard to take into the account number of available bytes / buffers; add missing read enable.