sort send and receive