OSDN Git Service

libceph: don't overwrite specific con error msgs
authorIlya Dryomov <idryomov@gmail.com>
Mon, 23 Mar 2015 11:52:40 +0000 (14:52 +0300)
committerIlya Dryomov <idryomov@gmail.com>
Mon, 20 Apr 2015 15:55:37 +0000 (18:55 +0300)
commit67c64eb742a49d3d3f5dcef75d0c32a3394e5519
tree3ec2a92411b449db348df22d76b1f8f20c05fa4d
parent1c841a96b5f369cbb0b169d13825c7ff7d0fba8d
libceph: don't overwrite specific con error msgs

- specific con->error_msg messages (e.g. "protocol version mismatch")
  end up getting overwritten by a catch-all "socket error on read
  / write", introduced in commit 3a140a0d5c4b ("libceph: report socket
  read/write error message")
- "bad message sequence # for incoming message" loses to "bad crc" due
  to the fact that -EBADMSG is used for both

Fix it, and tidy up con->error_msg assignments and pr_errs while at it.

Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
net/ceph/messenger.c