Skip to content

msg/msg_types: entity_addrvec_t: fix decode on big-endian hosts#35920

Merged
tchaikov merged 1 commit intoceph:masterfrom
uweigand:entity-addrvec-fix
Jul 6, 2020
Merged

msg/msg_types: entity_addrvec_t: fix decode on big-endian hosts#35920
tchaikov merged 1 commit intoceph:masterfrom
uweigand:entity-addrvec-fix

Conversation

@uweigand
Copy link
Copy Markdown
Contributor

@uweigand uweigand commented Jul 3, 2020

When decoding an entity_addrvec_t with marker 1, we just have
a single (non-legacy) entity_addr_t. This should be decoded
exactly the same as done by entity_addr_t::decode, but it
currently is not. Specifically, the sa_family member of
the sockaddr is not converted from the on-wire little-endian
format to host byte order (as done by entity_addr_t::decode).

Fixed by using the same code as in entity_addr_t::decode.

Signed-off-by: Ulrich Weigand ulrich.weigand@de.ibm.com

Checklist

  • References tracker ticket
  • Updates documentation if necessary
  • Includes tests for new functionality or reproducer for bug

Show available Jenkins commands
  • jenkins retest this please
  • jenkins test classic perf
  • jenkins test crimson perf
  • jenkins test signed
  • jenkins test make check
  • jenkins test make check arm64
  • jenkins test submodules
  • jenkins test dashboard
  • jenkins test dashboard backend
  • jenkins test docs
  • jenkins render docs
  • jenkins test ceph-volume all
  • jenkins test ceph-volume tox

When decoding an entity_addrvec_t with marker 1, we just have
a single (non-legacy) entity_addr_t.  This should be decoded
exactly the same as done by entity_addr_t::decode, but it
currently is not.  Specifically, the sa_family member of
the sockaddr is not converted from the on-wire little-endian
format to host byte order (as done by entity_addr_t::decode).

Fixed by using the same code as in entity_addr_t::decode.

Signed-off-by: Ulrich Weigand <ulrich.weigand@de.ibm.com>
@uweigand
Copy link
Copy Markdown
Contributor Author

uweigand commented Jul 3, 2020

jenkins retest this please

@batrick batrick added messenger Issues involving one of the Ceph messenger implementations needs-review labels Jul 4, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

messenger Issues involving one of the Ceph messenger implementations needs-review wip-kefu-testing

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants