diff options
author | Sage Weil <sage@newdream.net> | 2010-01-27 14:26:11 -0800 |
---|---|---|
committer | Sage Weil <sage@newdream.net> | 2010-01-27 14:29:11 -0800 |
commit | adeb0be15dc0d7d3f1604fdea0dd965095680f5a (patch) | |
tree | ef66241a9f6bc79c2fc7bb9798598402b6799e72 /src/msg/msg_types.h | |
parent | eebe6df5c2bb2bff8a0b2c7b9fba60ea159720f0 (diff) | |
download | ceph-adeb0be15dc0d7d3f1604fdea0dd965095680f5a.tar.gz |
msg: add type to ceph_entity_addr
Diffstat (limited to 'src/msg/msg_types.h')
-rw-r--r-- | src/msg/msg_types.h | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/src/msg/msg_types.h b/src/msg/msg_types.h index cd4b1dd1342..f0560202307 100644 --- a/src/msg/msg_types.h +++ b/src/msg/msg_types.h @@ -129,13 +129,15 @@ static inline void decode(sockaddr_storage& a, bufferlist::iterator& bl) { } struct entity_addr_t { - __u64 nonce; + __u32 type; + __u32 nonce; sockaddr_storage addr; - entity_addr_t() : nonce(0) { + entity_addr_t() : type(0), nonce(0) { memset(&addr, 0, sizeof(addr)); } entity_addr_t(const ceph_entity_addr &o) { + type = o.type; nonce = o.nonce; addr = o.in_addr; addr.ss_family = ntohs(addr.ss_family); @@ -186,6 +188,7 @@ struct entity_addr_t { operator ceph_entity_addr() const { ceph_entity_addr a; + a.type = 0; a.nonce = nonce; a.in_addr = addr; a.in_addr.ss_family = htons(addr.ss_family); @@ -223,10 +226,12 @@ struct entity_addr_t { } void encode(bufferlist& bl) const { + ::encode(type, bl); ::encode(nonce, bl); ::encode(addr, bl); } void decode(bufferlist::iterator& bl) { + ::decode(type, bl); ::decode(nonce, bl); ::decode(addr, bl); } |