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
Coverity and SCA fixes #7784
Coverity and SCA fixes #7784
Conversation
@dalgaaf why did you add the DNM prefix? |
eb45f0a
to
9401b33
Compare
FS/MDS patches look good. |
2fdab0c
to
265cdaf
Compare
@tchaikov: added the DNM because the build check failed and I'm not completely sure if this is caused by the commits. |
quite a few of the cli tests failed, in the cases of failures, the cli tools printed nothing.
|
265cdaf
to
bc4e086
Compare
@tchaikov: should work now, fixed the ConfUtils.cc patch |
bc4e086
to
b2f1630
Compare
rebased to master |
9ee8f03
to
236421c
Compare
Rebased and dropped one patch that was committed by someone else. Please review! |
2fe6216
to
0613ad1
Compare
rebased again ... would be nice if we can get this patch series merged |
ret = rgw_lookup(fs, fs->root_fh, get<0>(fid).c_str(), &rgw_fh, | ||
0 /* flags */); | ||
ASSERT_EQ(ret, 0); | ||
ASSERT_EQ(0, rgw_lookup(fs, fs->root_fh, get<0>(fid).c_str(), &rgw_fh, 0 /* flags */)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
maybe wrap this line so it does not exceed 80 chars?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not that I want to be nit-picking, but the source has at least ~17000 lines of code that exceed the 80 char limit. Is this something we start to enforce now? But I will change it anyway if this is what you want.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i agreed. we do not enforce this. but per https://github.com/ceph/ceph/blob/master/CodingStyle, we suggest using https://google.github.io/styleguide/cppguide.html as a baseline, which in turn puts this limit. see https://google.github.io/styleguide/cppguide.html#Line_Length
lgtm modulo some nits. |
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
Fixup for: CID 1351687 (#1 of 1): Uninitialized scalar variable (UNINIT) var_decl: Declaring variable lock_type without initializer uninit_use: Using uninitialized value lock_type. Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
Fix for: CID 1313448 (#1 of 1): Uninitialized scalar variable (UNINIT) uninit_use: Using uninitialized value want[i + this->k] Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
Fix for: CID 1254379 (#1 of 1): Uninitialized scalar variable (UNINIT) uninit_use_in_call: Using uninitialized value c when calling write. Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
Fix for: CID 1128394 (#1 of 1): Integer overflowed argument (INTEGER_OVERFLOW) overflow: Add operation overflows on operands line_len and 1UL. overflow_assign: Assigning overflowed or truncated value (or a value computed from an overflowed or a truncated value) to rem. overflow_sink: Overflowed or truncated value (or a value computed from an overflowed or truncated value) rem used as critical argument to function. Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
Add missing option to the correct section to fix build warnings. Resort the 'Options' section to alphabetical order. Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
Fix for: CID 1353420 (#1 of 1): Uninitialized pointer field (UNINIT_CTOR) uninit_member: Non-static class member cct is not initialized in this constructor nor in any functions that it calls. uninit_member: Non-static class member store is not initialized in this constructor nor in any functions that it calls. CID 1353421 (#1 of 1): Uninitialized pointer field (UNINIT_CTOR) uninit_member: Non-static class member cct is not initialized in this constructor nor in any functions that it calls. uninit_member: Non-static class member store is not initialized in this constructor nor in any functions that it calls. CID 1353427 (#1 of 1): Uninitialized pointer field (UNINIT_CTOR) uninit_member: Non-static class member cct is not initialized in this constructor nor in any functions that it calls. uninit_member: Non-static class member store is not initialized in this constructor nor in any functions that it calls. Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
Fix for: CID 1297862 (#1 of 1): Out-of-bounds access (OVERRUN) alloc_strlen: Allocating insufficient memory for the terminating null of the string. Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
CID 1351705 (#1 of 1): Uninitialized scalar field (UNINIT_CTOR) uninit_member: Non-static class member daily_loadavg is not initialized in this constructor nor in any functions that it calls. Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
CID 1351707 (#1 of 1): Uninitialized scalar field (UNINIT_CTOR) uninit_member: Non-static class member offset is not initialized in this constructor nor in any functions that it calls. uninit_member: Non-static class member length is not initialized in this constructor nor in any functions that it calls. Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
Fix for: CID 1351706 (#1 of 1): Uninitialized scalar field (UNINIT_CTOR) uninit_member: Non-static class member nid_last is not initialized in this constructor nor in any functions that it calls. Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
CID 1351708 (#1 of 1): Uninitialized scalar field (UNINIT_CTOR) uninit_member: Non-static class member code is not initialized in this constructor nor in any functions that it calls. Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
Fix for: CID 1353422 (#1 of 1): Uninitialized pointer field (UNINIT_CTOR) uninit_member: Non-static class member cct is not initialized in this constructor nor in any functions that it calls. uninit_member: Non-static class member store is not initialized in this constructor nor in any functions that it calls. CID 1353426 (#1 of 1): Uninitialized pointer field (UNINIT_CTOR) uninit_member: Non-static class member cct is not initialized in this constructor nor in any functions that it calls. uninit_member: Non-static class member store is not initialized in this constructor nor in any functions that it calls. Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
Fix for: CID 1351734 (#1 of 1): Uninitialized scalar field (UNINIT_CTOR) uninit_member: Non-static class member result is not initialized in this constructor nor in any functions that it calls. Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
Fix for: CID 717232 (#1 of 1): Uninitialized scalar field (UNINIT_CTOR) uninit_member: Non-static class member cap_id is not initialized in this constructor nor in any functions that it calls. uninit_member: Non-static class member wanted is not initialized in this constructor nor in any functions that it calls. uninit_member: Non-static class member issued is not initialized in this constructor nor in any functions that it calls. uninit_member: Non-static class member pending is not initialized in this constructor nor in any functions that it calls. uninit_member: Non-static class member seq is not initialized in this constructor nor in any functions that it calls. uninit_member: Non-static class member mseq is not initialized in this constructor nor in any functions that it calls. Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
Fix for: CID 1351689 (#1 of 1): Uninitialized scalar field (UNINIT_CTOR) uninit_member: Non-static class member total_size is not initialized in this constructor nor in any functions that it calls. Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
Fix for: CID 1313449 (#1 of 1): Uninitialized scalar field (UNINIT_CTOR) uninit_member: Non-static class member force_init is not initialized in this constructor nor in any functions that it calls. Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
Fix for: CID 1274314 (#1 of 1): Uninitialized scalar field (UNINIT_CTOR) uninit_member: Non-static class member m_header_crc is not initialized in this constructor nor in any functions that it calls. Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
Fix for: CID 1138591 (#1 of 1): Uninitialized scalar field (UNINIT_CTOR) uninit_member: Non-static class member cap_id is not initialized in this constructor nor in any functions that it calls. uninit_member: Non-static class member issue_seq is not initialized in this constructor nor in any functions that it calls. uninit_member: Non-static class member mseq is not initialized in this constructor nor in any functions that it calls. Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
Fix for: CID 1019612 (#1 of 1): Uninitialized scalar field (UNINIT_CTOR) uninit_member: Non-static class member before is not initialized in this constructor nor in any functions that it calls. uninit_member: Non-static class member seq is not initialized in this constructor nor in any functions that it calls. uninit_member: Non-static class member last_issue is not initialized in this constructor nor in any functions that it calls. Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
Fix for: CID 717368 (#1 of 1): Uninitialized scalar field (UNINIT_CTOR) uninit_member: Non-static class member is_truncated is not initialized in this constructor nor in any functions that it calls. Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
dea1d02
to
79d658f
Compare
Build fix:
SCA:
Coverity: