]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
rbd-ggate: fix fallout from bufferlist.copy() change 33057/head
authorWillem Jan Withagen <wjw@digiware.nl>
Tue, 4 Feb 2020 11:19:43 +0000 (12:19 +0100)
committerWillem Jan Withagen <wjw@digiware.nl>
Tue, 4 Feb 2020 13:07:00 +0000 (14:07 +0100)
fixes: #3281
Signed-off-by: Willem Jan Withagen <wjw@digiware.nl>
src/tools/rbd_ggate/Driver.cc

index 752ef56f8cc121d3fc82854d3f86c52091ee13cd..80acfe00c56273fe341915a4e221a9a57aa74c3d 100644 (file)
@@ -149,7 +149,7 @@ int Driver::send(Request *req) {
       ggate_drv_req_error(req->req) == 0) {
     ceph_assert(req->bl.length() == ggate_drv_req_length(req->req));
     // TODO: avoid copying?
-    req->bl.copy(0, ggate_drv_req_length(req->req),
+    req->bl.begin().copy(ggate_drv_req_length(req->req),
                  static_cast<char *>(ggate_drv_req_buf(req->req)));
     dout(20) << "copied resulting " << req->bl.length() << " bytes to "
              << ggate_drv_req_buf(req->req) << dendl;