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

messages: default-initialize MOSDPGRecoveryDelete[Reply] members #16584

Merged
merged 1 commit into from Jul 27, 2017

Conversation

Projects
None yet
3 participants
@gregsfortytwo
Copy link
Member

gregsfortytwo commented Jul 26, 2017

This makes Coverity happy and is good practice, even though we do
a member-by-member initialization in the only place we create these messages.

Signed-off-by: Greg Farnum gfarnum@redhat.com

messages: default-initialize MOSDPGRecoveryDelete[Reply] members
This makes Coverity happy and is good practice, even though we do
a member-by-member initialization in the only place we create these messages.

Signed-off-by: Greg Farnum <gfarnum@redhat.com>
@@ -53,7 +53,8 @@ struct MOSDPGRecoveryDelete : public MOSDFastDispatchOp {
from(from),
pgid(pgid),
map_epoch(map_epoch),
min_epoch(min_epoch) {}
min_epoch(min_epoch),
cost(0) {}

This comment has been minimized.

Copy link
@joscollin

joscollin Jul 26, 2017

Member

I would prefer cost to be initialized at the declaration itself. Otherwise, another overloading constructor may create the same problem (coverity unhappy) again in the future :-).

@joscollin joscollin merged commit 0a8becf into ceph:master Jul 27, 2017

4 checks passed

Signed-off-by all commits in this PR are signed
Details
Unmodified Submodules submodules for project are unmodified
Details
make check make check succeeded
Details
make check (arm64) make check succeeded
Details

@gregsfortytwo gregsfortytwo deleted the gregsfortytwo:wip-deletes-coverity branch Jul 27, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.