Skip to content

Conversation

@esilvade-wr
Copy link

The function 'execute_ceph_cmd' in ceph_common.sh executes ceph commands and stores the return code in the variable 'errcode'. However, instead of returning this value, the return is always 1.

To ensure we know the correct return code for the executed command, the variable errcode is returned instead of 1.

In addition, the lines in the wlog were also corrected, because if the 'name' variable was empty, the rest of the content would no longer be printed; therefore, double quotes were added to prevent this from happening.

Test Plan:

  • PASS: Run the script and verify that the return code is being returned as expected.
  • PASS: Check if the logs are being printed correctly.

Partial-Bug: https://launchpad.net/bugs/2098031

The function 'execute_ceph_cmd' in ceph_common.sh executes ceph
commands and stores the return code in the variable 'errcode'.
However, instead of returning this value, the return is always 1.

To ensure we know the correct return code for the executed command,
the variable `errcode` is returned instead of 1.

In addition, the lines in the wlog were also corrected, because if
the 'name' variable was empty, the rest of the content would no
longer be printed; therefore, double quotes were added to
prevent this from happening.

Test Plan:
- PASS: Run the script and verify that the return code is being
	returned as expected.
- PASS: Check if the logs are being printed correctly.

Partial-Bug: https://launchpad.net/bugs/2098031

Signed-off-by: Erickson Silva de Oliveira <[email protected]>
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.

1 participant