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

Some more SCA fixes #162

Merged
merged 10 commits into from
Jun 12, 2018
Merged

Some more SCA fixes #162

merged 10 commits into from
Jun 12, 2018

Conversation

dalgaaf
Copy link
Collaborator

@dalgaaf dalgaaf commented Jun 8, 2018

  • update gitignore
  • memory leak
  • error handling
  • nullptr deref
  • not needed assignments
  • reduce scope of vars
  • unused vars

dalgaaf added 10 commits June 6, 2018 06:57
Signed-off-by: Danny Al-Gaaf <[email protected]>
Make sure int and bool return values are handled correctly. Handle
all error cases and return the correct error values. Fixup move_to_alt()
to detect the return value, 0 is already an error.

Signed-off-by: Danny Al-Gaaf <[email protected]>
Fix for:

[src/dict-rados/dict-rados.cpp:190] -> [src/dict-rados/dict-rados.cpp:176]: (warning)
 Either the condition '_dict!=NULL' is redundant or there is possible null
 pointer dereference: dict.

Signed-off-by: Danny Al-Gaaf <[email protected]>
Fix for:

[src/dict-rados/dict-rados.cpp:557] -> [src/dict-rados/dict-rados.cpp:562]: (style)
 Variable 'ret' is reassigned a value before the old one has been used.

Signed-off-by: Danny Al-Gaaf <[email protected]>
Fix for:

[src/librmb/rados-ceph-json-config.cpp:121] -> [src/librmb/rados-ceph-json-config.cpp:135]:
 (style) Variable 's' is reassigned a value before the old one has been used.

Signed-off-by: Danny Al-Gaaf <[email protected]>
Some fixes, including adding some missing return value checks
in the test code, adding some tags to suppress warnings and
removing some not needed initialization of variables.

Signed-off-by: Danny Al-Gaaf <[email protected]>
@jrse jrse merged commit c8e844f into master Jun 12, 2018
@jrse jrse deleted the wip-da-SCA-20180606 branch September 27, 2022 20:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants