]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
src/tools: fix printing wrong offset.
authormyoungwon oh <omwmw@sk.com>
Tue, 9 Apr 2019 08:00:18 +0000 (17:00 +0900)
committermyoungwon oh <omwmw@sk.com>
Thu, 11 Apr 2019 08:03:44 +0000 (17:03 +0900)
Signed-off-by: Myoungwon Oh <ommw@sk.com>
src/common/rabin.cc
src/tools/ceph_dedup_tool.cc

index 4980960563aad352bbe760ded7e104b7202443a7..794627a09aa76ebc37a6f660e5f4713bc61b8cf4 100644 (file)
@@ -130,4 +130,5 @@ int RabinChunk::do_rabin_chunks(bufferlist & inputdata,
     chunks.push_back(make_pair(c_start, c_size));
   }
 
+  return 0;
 }
index f3a53ef5ca799762be66eb9e5efda97fc72f0772..fa89d340f450ef089ffd1879dc65af70016ec301 100644 (file)
@@ -440,7 +440,7 @@ uint64_t EstimateDedupRatio::rabin_chunk(string oid, uint64_t offset)
     chunk.append(c_data);
     chunk.copy_in(0, p.second, outdata.c_str() + p.first);
     add_chunk_fp_to_stat(chunk);
-    cout << " oid: " << oid <<  " offset: " << p.first << " length: " << p.second << std::endl;
+    cout << " oid: " << oid <<  " offset: " << p.first + offset << " length: " << p.second << std::endl;
   }
 
   if (outdata.length() < op_size) {