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

Fix row level repair uninitialized member #5532

Merged
merged 2 commits into from
Dec 31, 2019

Conversation

bhalevy
Copy link
Member

@bhalevy bhalevy commented Dec 30, 2019

Initialize bool members in row_level_repair and _storage_service` causing ubsan errors.

Fixes #5531

Avoid following UBSAN error:
repair/row_level.cc:2141:7: runtime error: load of value 240, which is not a valid value for type 'bool'

Fixes scylladb#5531

Signed-off-by: Benny Halevy <bhalevy@scylladb.com>
Hit the following ubsan error with bootstrap_test:TestBootstrap.manual_bootstrap_test in debug mode:
  service/storage_service.cc:3519:37: runtime error: load of value 190, which is not a valid value for type 'bool'

The use site is:
  service::storage_service::is_cleanup_allowed(seastar::basic_sstring<char, unsigned int, 15u, true>)::{lambda(service::storage_service&)scylladb#1}::operator()(service::storage_service&) const at /local/home/bhalevy/dev/scylla/service/storage_service.cc:3519

While at it, initialize `_initialized` to false as well, just in case.

Signed-off-by: Benny Halevy <bhalevy@scylladb.com>
@bhalevy bhalevy requested a review from asias December 30, 2019 09:52
@asias
Copy link
Contributor

asias commented Dec 31, 2019

Looks good to me.

@bhalevy
Copy link
Member Author

bhalevy commented Dec 31, 2019

@scylladb/scylla-maint please merge

nyh added a commit that referenced this pull request Dec 31, 2019
Merged pull request #5532 from
Benny Halevy:

Initialize bool members in row_level_repair and _storage_service causing
ubsan errors.

Fixes #5531
@nyh nyh merged commit 8aa5d84 into scylladb:next Dec 31, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants