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

test: Division by zero in Legacy::encode_n() #15902

Merged
merged 1 commit into from Jun 26, 2017

Conversation

Projects
None yet
3 participants
@joscollin
Member

joscollin commented Jun 24, 2017

Fixes the Coverity Scan Report:

CID 1411820 (#1 of 1): Division or modulo by zero (DIVIDE_BY_ZERO)
9. divide_by_zero: In expression bl.length() * i / sum, division by expression sum which may be zero has undefined behavior.

Signed-off-by: Jos Collin jcollin@redhat.com

test: Division by zero in Legacy::encode_n()
Fixes the Coverity Scan Report:
CID 1411820 (#1 of 1): Division or modulo by zero (DIVIDE_BY_ZERO)
9. divide_by_zero: In expression bl.length() * i / sum, division by expression sum which may be zero has undefined behavior.

Signed-off-by: Jos Collin <jcollin@redhat.com>
@joscollin

This comment has been minimized.

Member

joscollin commented Jun 25, 2017

Jenkins Retest this please

@badone

badone approved these changes Jun 25, 2017

LGTM

@joscollin joscollin merged commit 0d1e197 into ceph:master Jun 26, 2017

4 checks passed

Signed-off-by all commits in this PR are signed
Details
Unmodified Submodules submodules for project are unmodified
Details
default Build finished.
Details
make check make check succeeded
Details

@joscollin joscollin deleted the joscollin:wip-1411820-Division-or-modulo-by-zero branch Jun 26, 2017

@tchaikov

This comment has been minimized.

Contributor

tchaikov commented Jul 18, 2017

@joscollin please make sure the "Reviewed-by" line looks right before merging a PR. in this case it is

Reviewed By: Brad Hubbard <bhubbard@redhat.com>
@joscollin

This comment has been minimized.

Member

joscollin commented Jul 18, 2017

@tchaikov Sorry, during those days I copy paste it, as I was not sure about the format.
It was a copy pasted from here: 8ebb13e

Now I write it myself, so no problems. Thanks.

@joscollin

This comment has been minimized.

Member

joscollin commented Jul 18, 2017

@tchaikov Sorry, wrong url in the previous message. That was copied from here:
954f193

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment