From: Greg Farnum Date: Fri, 18 Jan 2013 21:08:03 +0000 (-0800) Subject: mds: EUpdate event now uses modern encoding X-Git-Tag: v0.58~100^2~10 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=05461e8d0490e6fde2a09913bcea5142b4a4b12a;p=ceph.git mds: EUpdate event now uses modern encoding Signed-off-by: Greg Farnum --- diff --git a/src/mds/events/EUpdate.h b/src/mds/events/EUpdate.h index a302a5a2b6f..9a1aceb3857 100644 --- a/src/mds/events/EUpdate.h +++ b/src/mds/events/EUpdate.h @@ -39,8 +39,7 @@ public: } void encode(bufferlist &bl) const { - __u8 struct_v = 3; - ::encode(struct_v, bl); + ENCODE_START(4, 4, bl); ::encode(stamp, bl); ::encode(type, bl); ::encode(metablob, bl); @@ -48,10 +47,10 @@ public: ::encode(cmapv, bl); ::encode(reqid, bl); ::encode(had_slaves, bl); + ENCODE_FINISH(bl); } void decode(bufferlist::iterator &bl) { - __u8 struct_v; - ::decode(struct_v, bl); + DECODE_START_LEGACY_COMPAT_LEN(4, 4, 4, bl); if (struct_v >= 2) ::decode(stamp, bl); ::decode(type, bl); @@ -61,6 +60,7 @@ public: ::decode(cmapv, bl); ::decode(reqid, bl); ::decode(had_slaves, bl); + DECODE_FINISH(bl); } void update_segment();