From: Danny Al-Gaaf Date: Thu, 28 Feb 2013 14:56:22 +0000 (+0100) Subject: cls_rbd.cc: remove unused variable X-Git-Tag: v0.59~61^2~7 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=9f98b80f2ec596dd99c3e1addd01403ff5f5514e;p=ceph.git cls_rbd.cc: remove unused variable Remove unused variable 'len', left over from commit 0b0009cfe8429072ba2af6f6843537d5501b27c3. Signed-off-by: Danny Al-Gaaf --- diff --git a/src/cls/rbd/cls_rbd.cc b/src/cls/rbd/cls_rbd.cc index 3088f38178b5..982c8a66798c 100644 --- a/src/cls/rbd/cls_rbd.cc +++ b/src/cls/rbd/cls_rbd.cc @@ -1836,7 +1836,6 @@ int old_snapshot_add(cls_method_context_t hctx, bufferlist *in, bufferlist *out) header = (struct rbd_obj_header_ondisk *)bl.c_str(); int snaps_id_ofs = sizeof(*header); - int len = snaps_id_ofs; int names_ofs = snaps_id_ofs + sizeof(*new_snaps) * header->snap_count; const char *snap_name; const char *snap_names = ((char *)header) + names_ofs; @@ -1885,8 +1884,6 @@ int old_snapshot_add(cls_method_context_t hctx, bufferlist *in, bufferlist *out) new_snaps[0].id = snap_id; new_snaps[0].image_size = header->image_size; - len += sizeof(*new_snaps) * header->snap_count + header->snap_names_len; - memcpy(header_bp.c_str(), header, sizeof(*header)); newbl.push_back(header_bp);