Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

os/bluestore: fix offset bug in _do_write_small. #11030

Merged
merged 2 commits into from
Sep 13, 2016
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/os/bluestore/BlueStore.cc
Original file line number Diff line number Diff line change
Expand Up @@ -6964,7 +6964,7 @@ void BlueStore::_do_write_small(
if (ep != o->extent_map.extent_map.begin()) {
--ep;
b = ep->blob;
if (ep->logical_offset + b->get_blob().get_ondisk_length() <= offset) {
if ((ep->logical_offset - ep->blob_offset) + b->get_blob().get_ondisk_length() <= offset) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No need for parentheses.
Have you run ceph_test_objectstore for your patch?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I ran ceph_test_objectstore(only BlueStore), here is the result.

[----------] Global test environment tear-down
[==========] 61 tests from 1 test case ran. (9295011 ms total)
[ PASSED ] 61 tests.

++ep;
}
}
Expand Down