From: Sage Weil Date: Mon, 20 Feb 2012 18:56:25 +0000 (-0800) Subject: osdmap: successfully decode short map X-Git-Tag: v0.43~47^2~2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=f3a273a65710f940c969c6357123449f152ace56;p=ceph.git osdmap: successfully decode short map When we send (old) maps to the kclient, we omit the extended section. Lets decode those (old, abbreviated maps) successfully, too. Signed-off-by: Sage Weil --- diff --git a/src/osd/OSDMap.cc b/src/osd/OSDMap.cc index a2d92586834..e8cc15ac606 100644 --- a/src/osd/OSDMap.cc +++ b/src/osd/OSDMap.cc @@ -243,6 +243,10 @@ void OSDMap::Incremental::decode(bufferlist::iterator &p) ::decode(new_pg_temp, p); } + // decode short map, too. + if (v == 5 && p.end()) + return; + // extended __u16 ev = 0; if (v >= 5)