update send/recv calls

Prefer that calls return success or failure with the actual data
sent or recvd passed as a parameter. The sendall and recvall calls
are added for convenience and renamed for clarity.