modify sendNACK and add a send thread