toolbox-0.1.1-1.fc42

List of Findings

Error: SHELLCHECK_WARNING (CWE-569): [#def1]
/usr/share/bash-completion/completions/toolbox.bash:117:23: warning[SC2048]: Use "${array[@]}" (with quotes) to prevent whitespace problems.
#  115|           # Do not use quotes around the $completions variable or else newline
#  116|           # characters will be kept.
#  117|->         for filter in ${completions[*]}; do
#  118|               fullFilter+="$filter|"
#  119|           done

Error: SHELLCHECK_WARNING (CWE-563): [#def2]
/usr/share/bash-completion/completions/toolbox.bash:151:13: warning[SC2034]: x appears unused. Verify use (or export if used externally).
#  149|           # The prompt format is only available from bash 4.4.
#  150|           # We test if it is available before using it.
#  151|->         if (x=${PS1@P}) 2> /dev/null; then
#  152|               printf "%s" "${PS1@P}${COMP_LINE[@]}"
#  153|           else

Error: SHELLCHECK_WARNING (CWE-138): [#def3]
/usr/share/bash-completion/completions/toolbox.bash:152:34: error[SC2145]: Argument mixes string and array. Use * or separate argument.
#  150|           # We test if it is available before using it.
#  151|           if (x=${PS1@P}) 2> /dev/null; then
#  152|->             printf "%s" "${PS1@P}${COMP_LINE[@]}"
#  153|           else
#  154|               # Can't print the prompt.  Just print the

Error: SHELLCHECK_WARNING (CWE-153): [#def4]
/usr/share/bash-completion/completions/toolbox.bash:168:37: warning[SC2053]: Quote the right-hand side of == in [[ ]] to prevent glob matching.
#  166|   
#  167|       while IFS='' read -r comp; do
#  168|->         if [[ ${comp:0:endIndex} == $activeHelpMarker ]]; then
#  169|               comp=${comp:endIndex}
#  170|               __toolbox_debug "ActiveHelp found: $comp"

Error: SHELLCHECK_WARNING (CWE-563): [#def5]
/usr/share/bash-completion/completions/toolbox.bash:305:15: warning[SC2034]: prev appears unused. Verify use (or export if used externally).
#  303|   __start_toolbox()
#  304|   {
#  305|->     local cur prev words cword split
#  306|   
#  307|       COMPREPLY=()

Error: SHELLCHECK_WARNING (CWE-563): [#def6]
/usr/share/bash-completion/completions/toolbox.bash:305:32: warning[SC2034]: split appears unused. Verify use (or export if used externally).
#  303|   __start_toolbox()
#  304|   {
#  305|->     local cur prev words cword split
#  306|   
#  307|       COMPREPLY=()

Error: SHELLCHECK_WARNING (CWE-457): [#def7]
/usr/share/toolbox/test/system/libs/bats-assert/src/assert.bash:109:9: warning[SC2154]: status is referenced but not assigned.
#  107|   #   STDERR - details, on failure
#  108|   assert_success() {
#  109|->   if (( status != 0 )); then
#  110|       { local -ir width=6
#  111|         batslib_print_kv_single "$width" 'status' "$status"

Error: SHELLCHECK_WARNING: [#def8]
/usr/share/toolbox/test/system/libs/bats-assert/src/assert.bash:230:36: warning[SC2319]: This $? refers to a condition, not a command. Assign to a variable to avoid it being overwritten.
#  228|       fi
#  229|     elif (( is_mode_regexp )); then
#  230|->     if [[ '' =~ $expected ]] || (( $? == 2 )); then
#  231|         echo "Invalid extended regular expression: \`$expected'" \
#  232|           | batslib_decorate 'ERROR: assert_output' \

Error: SHELLCHECK_WARNING: [#def9]
/usr/share/toolbox/test/system/libs/bats-assert/src/assert.bash:347:43: warning[SC2319]: This $? refers to a condition, not a command. Assign to a variable to avoid it being overwritten.
#  345|       fi
#  346|     elif (( is_mode_regexp )); then
#  347|->     if [[ $output =~ $unexpected ]] || (( $? == 0 )); then
#  348|         batslib_print_kv_single_or_multi 6 \
#  349|             'regexp'  "$unexpected" \

Error: SHELLCHECK_WARNING (CWE-457): [#def10]
/usr/share/toolbox/test/system/libs/bats-assert/src/assert.bash:464:15: warning[SC2154]: lines is referenced but not assigned.
#  462|       # Specific line.
#  463|       if (( is_mode_regexp )); then
#  464|->       if ! [[ ${lines[$idx]} =~ $expected ]]; then
#  465|           batslib_print_kv_single 6 \
#  466|               'index' "$idx" \

Error: SHELLCHECK_WARNING: [#def11]
/usr/share/toolbox/test/system/libs/bats-assert/src/assert.bash:644:52: warning[SC2319]: This $? refers to a condition, not a command. Assign to a variable to avoid it being overwritten.
#  642|       # Specific line.
#  643|       if (( is_mode_regexp )); then
#  644|->       if [[ ${lines[$idx]} =~ $unexpected ]] || (( $? == 0 )); then
#  645|           batslib_print_kv_single 6 \
#  646|               'index' "$idx" \

Error: SHELLCHECK_WARNING (CWE-685): [#def12]
/usr/share/toolbox/test/system/libs/bats-support/src/output.bash:215:1: warning[SC2120]: batslib_prefix references arguments, but none are ever passed.
#  213|   # Outputs:
#  214|   #   STDOUT - prefixed lines
#  215|-> batslib_prefix() {
#  216|     local -r prefix="${1:-  }"
#  217|     local line

Error: SHELLCHECK_WARNING (CWE-156): [#def13]
/usr/share/toolbox/test/system/libs/bats-support/src/output.bash:243:10: warning[SC2046]: Quote this to prevent word splitting.
#  241|     local -r symbol="$1"; shift
#  242|     # Sort line numbers.
#  243|->   set -- $( sort -nu <<< "$( printf '%d\n' "$@" )" )
#  244|   
#  245|     local line

Scan Properties

analyzer-version-clippy1.82.0
analyzer-version-cppcheck2.16.0
analyzer-version-gcc14.2.1
analyzer-version-gcc-analyzer15.0.0
analyzer-version-shellcheck0.10.0
analyzer-version-unicontrol0.0.2
enabled-pluginsclippy, cppcheck, gcc, shellcheck, unicontrol
exit-code0
hostip-172-16-1-115.us-west-2.compute.internal
mock-configfedora-rawhide-gcc-latest-x86_64
project-nametoolbox-0.1.1-1.fc42
store-results-to/tmp/tmpzmxg9shi/toolbox-0.1.1-1.fc42.tar.xz
time-created2024-11-13 03:28:39
time-finished2024-11-13 03:31:00
toolcsmock
tool-args'/usr/bin/csmock' '-r' 'fedora-rawhide-gcc-latest-x86_64' '-t' 'clippy,cppcheck,gcc,unicontrol,shellcheck' '-o' '/tmp/tmpzmxg9shi/toolbox-0.1.1-1.fc42.tar.xz' '--gcc-analyze' '--unicontrol-notests' '--unicontrol-bidi-only' '--install=gcc-latest' '--gcc-analyzer-bin=/opt/gcc-latest/bin/gcc' '/tmp/tmpzmxg9shi/toolbox-0.1.1-1.fc42.src.rpm'
tool-versioncsmock-3.7.1.20241107.094801.gb3f0f26.pr_192-1.el9