From: myoungwon oh Date: Tue, 9 Apr 2019 08:00:18 +0000 (+0900) Subject: src/tools: fix printing wrong offset. X-Git-Tag: v15.1.0~2835^2~2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=cd139974ceb42f96156fc3f93629b29eea2b6362;p=ceph.git src/tools: fix printing wrong offset. Signed-off-by: Myoungwon Oh --- diff --git a/src/common/rabin.cc b/src/common/rabin.cc index 4980960563a..794627a09aa 100644 --- a/src/common/rabin.cc +++ b/src/common/rabin.cc @@ -130,4 +130,5 @@ int RabinChunk::do_rabin_chunks(bufferlist & inputdata, chunks.push_back(make_pair(c_start, c_size)); } + return 0; } diff --git a/src/tools/ceph_dedup_tool.cc b/src/tools/ceph_dedup_tool.cc index f3a53ef5ca7..fa89d340f45 100644 --- a/src/tools/ceph_dedup_tool.cc +++ b/src/tools/ceph_dedup_tool.cc @@ -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) {