Error: SHELLCHECK_WARNING (CWE-477): [#def1] /usr/lib/rpm/redhat/brp-ldconfig:5:27: warning[SC2166]: Prefer [ p ] || [ q ] as [ p -o q ] is not well defined. # 3| # 4| # If using normal root, avoid changing anything. # 5|-> if [ -z "$RPM_BUILD_ROOT" -o "$RPM_BUILD_ROOT" = "/" ]; then # 6| exit 0 # 7| fi Error: SHELLCHECK_WARNING (CWE-156): [#def2] /usr/lib/rpm/redhat/brp-ldconfig:11:19: warning[SC2046]: Quote this to prevent word splitting. # 9| # Create an empty config file for ldconfig to shut up a warning # 10| config=$(mktemp -p "$RPM_BUILD_ROOT") # 11|-> /sbin/ldconfig -f $(basename "$config") -N -r "$RPM_BUILD_ROOT" # 12| rm -f "$config" # 13| # TODO: warn if it created new symlinks and guide people. Error: SHELLCHECK_WARNING (CWE-477): [#def3] /usr/lib/rpm/redhat/brp-mangle-shebangs:4:27: warning[SC2166]: Prefer [ p ] || [ q ] as [ p -o q ] is not well defined. # 2| # 3| # If using normal root, avoid changing anything. # 4|-> if [ -z "$RPM_BUILD_ROOT" -o "$RPM_BUILD_ROOT" = "/" ]; then # 5| exit 0 # 6| fi Error: SHELLCHECK_WARNING (CWE-569): [#def4] /usr/lib/rpm/redhat/config.sub:245:8: warning[SC2221]: This pattern always overrides a later one on line 247. # 243| | semi \ # 244| | sequent* \ # 245|-> | siemens \ # 246| | sgi* \ # 247| | siemens \ Error: SHELLCHECK_WARNING (CWE-569): [#def5] /usr/lib/rpm/redhat/config.sub:247:8: warning[SC2222]: This pattern never matches because of a previous pattern on line 245. # 245| | siemens \ # 246| | sgi* \ # 247|-> | siemens \ # 248| | sim \ # 249| | sni \ Error: SHELLCHECK_WARNING (CWE-456): [#def6] /usr/lib/rpm/redhat/dist.sh:41:2: warning[SC2209]: Use var=$(command) to assign output (or quote to assign string). # 39| if [ -n "$DISTNUM" ]; then # 40| if [ -n "$DISTFC" ]; then # 41|-> DISTTYPE=fc # 42| elif [ -n "$DISTRHEL" ]; then # 43| DISTTYPE=el Error: SHELLCHECK_WARNING (CWE-477): [#def7] /usr/lib/rpm/redhat/dist.sh:48:18: warning[SC2166]: Prefer [ p ] && [ q ] as [ p -a q ] is not well defined. # 46| fi # 47| fi # 48|-> [ -n "$DISTTYPE" -a -n "$DISTNUM" ] && DISTTAG=".${DISTTYPE}${DISTNUM}" # 49| # 50| case "$1" in Error: SHELLCHECK_WARNING (CWE-252): [#def8] /usr/lib/rpm/redhat/redhat-annobin-plugin-select.sh:183:5: warning[SC2164]: Use 'pushd ... || exit' or 'pushd ... || return' in case pushd fails. # 181| echo " redhat-rpm-config: Installing annobin version of $rac1" # 182| fi # 183|-> pushd $rrcdir > /dev/null # 184| rm -f $rac1 # 185| ln -s $select_annobin "$rac1" Error: SHELLCHECK_WARNING: [#def9] /usr/lib/rpm/redhat/redhat-annobin-plugin-select.sh:183:5: warning[SC3044]: In POSIX sh, 'pushd' is undefined. # 181| echo " redhat-rpm-config: Installing annobin version of $rac1" # 182| fi # 183|-> pushd $rrcdir > /dev/null # 184| rm -f $rac1 # 185| ln -s $select_annobin "$rac1" Error: SHELLCHECK_WARNING (CWE-252): [#def10] /usr/lib/rpm/redhat/redhat-annobin-plugin-select.sh:186:5: warning[SC2164]: Use 'popd ... || exit' or 'popd ... || return' in case popd fails. # 184| rm -f $rac1 # 185| ln -s $select_annobin "$rac1" # 186|-> popd > /dev/null # 187| # 188| else if [ $install_gcc_version -eq 1 ] Error: SHELLCHECK_WARNING: [#def11] /usr/lib/rpm/redhat/redhat-annobin-plugin-select.sh:186:5: warning[SC3044]: In POSIX sh, 'popd' is undefined. # 184| rm -f $rac1 # 185| ln -s $select_annobin "$rac1" # 186|-> popd > /dev/null # 187| # 188| else if [ $install_gcc_version -eq 1 ] Error: SHELLCHECK_WARNING (CWE-398): [#def12] /usr/lib/rpm/redhat/redhat-annobin-plugin-select.sh:188:1: error[SC1075]: Use 'elif' instead of 'else if' (or put 'if' on new line if nesting). # 186| popd > /dev/null # 187| # 188|-> else if [ $install_gcc_version -eq 1 ] # 189| then # 190| if [ $debug -eq 1 ] Error: SHELLCHECK_WARNING (CWE-252): [#def13] /usr/lib/rpm/redhat/redhat-annobin-plugin-select.sh:194:2: warning[SC2164]: Use 'pushd ... || exit' or 'pushd ... || return' in case pushd fails. # 192| echo " redhat-rpm-config: Installing gcc version of $rac1" # 193| fi # 194|-> pushd $rrcdir > /dev/null # 195| rm -f $rac1 # 196| ln -s $select_gcc $rac1 Error: SHELLCHECK_WARNING: [#def14] /usr/lib/rpm/redhat/redhat-annobin-plugin-select.sh:194:2: warning[SC3044]: In POSIX sh, 'pushd' is undefined. # 192| echo " redhat-rpm-config: Installing gcc version of $rac1" # 193| fi # 194|-> pushd $rrcdir > /dev/null # 195| rm -f $rac1 # 196| ln -s $select_gcc $rac1 Error: SHELLCHECK_WARNING (CWE-252): [#def15] /usr/lib/rpm/redhat/redhat-annobin-plugin-select.sh:197:2: warning[SC2164]: Use 'popd ... || exit' or 'popd ... || return' in case popd fails. # 195| rm -f $rac1 # 196| ln -s $select_gcc $rac1 # 197|-> popd > /dev/null # 198| fi # 199| fi Error: SHELLCHECK_WARNING: [#def16] /usr/lib/rpm/redhat/redhat-annobin-plugin-select.sh:197:2: warning[SC3044]: In POSIX sh, 'popd' is undefined. # 195| rm -f $rac1 # 196| ln -s $select_gcc $rac1 # 197|-> popd > /dev/null # 198| fi # 199| fi
analyzer-version-clippy | 1.86.0 |
analyzer-version-cppcheck | 2.17.1 |
analyzer-version-gcc | 15.0.1 |
analyzer-version-gcc-analyzer | 15.0.1 |
analyzer-version-shellcheck | 0.10.0 |
analyzer-version-unicontrol | 0.0.2 |
enabled-plugins | clippy, cppcheck, gcc, shellcheck, unicontrol |
exit-code | 0 |
host | ip-172-16-1-83.us-west-2.compute.internal |
known-false-positives | /usr/share/csmock/known-false-positives.js |
known-false-positives-rpm | known-false-positives-0.0.0.20250425.124705.g1c7c448.main-1.el9.noarch |
mock-config | fedora-rawhide-x86_64 |
project-name | redhat-rpm-config-343-4.fc43 |
store-results-to | /tmp/tmpckhnvamp/redhat-rpm-config-343-4.fc43.tar.xz |
time-created | 2025-04-25 15:28:08 |
time-finished | 2025-04-25 15:29:13 |
tool | csmock |
tool-args | '/usr/bin/csmock' '-r' 'fedora-rawhide-x86_64' '-t' 'unicontrol,cppcheck,gcc,clippy,shellcheck' '-o' '/tmp/tmpckhnvamp/redhat-rpm-config-343-4.fc43.tar.xz' '--gcc-analyze' '--unicontrol-notests' '--unicontrol-bidi-only' '--install' 'pam' '--gcc-analyzer-bin=/usr/bin/gcc' '/tmp/tmpckhnvamp/redhat-rpm-config-343-4.fc43.src.rpm' |
tool-version | csmock-3.8.1.20250422.172604.g26bc3d6-1.el9 |