From: Jason Dillaman Date: Tue, 18 Apr 2017 14:05:53 +0000 (-0400) Subject: librbd: corrected resize RPC message backwards compatibility X-Git-Tag: v12.0.2~28^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=refs%2Fpull%2F14615%2Fhead;p=ceph.git librbd: corrected resize RPC message backwards compatibility Commit d1f2c557 incorrectly changed the order of variables within the payload. This resulted in breaking the resize RPC message with older versions of Ceph. Fixes: http://tracker.ceph.com/issues/19636 Signed-off-by: Jason Dillaman --- diff --git a/src/librbd/WatchNotifyTypes.cc b/src/librbd/WatchNotifyTypes.cc index 4f7f1b0d7e55..b146eeac3a11 100644 --- a/src/librbd/WatchNotifyTypes.cc +++ b/src/librbd/WatchNotifyTypes.cc @@ -165,14 +165,14 @@ void AsyncCompletePayload::dump(Formatter *f) const { } void ResizePayload::encode(bufferlist &bl) const { - AsyncRequestPayloadBase::encode(bl); ::encode(size, bl); + AsyncRequestPayloadBase::encode(bl); ::encode(allow_shrink, bl); } void ResizePayload::decode(__u8 version, bufferlist::iterator &iter) { - AsyncRequestPayloadBase::decode(version, iter); ::decode(size, iter); + AsyncRequestPayloadBase::decode(version, iter); if (version >= 4) { ::decode(allow_shrink, iter);