Error: SHELLCHECK_WARNING (CWE-563): [#def1] /usr/bin/pdfroff:67:42: warning[SC2034]: NULLCMD appears unused. Verify use (or export if used externally). # 65| # then we may need this hack, adapted from autoconf code. # 66| # # 67|-> test x${ZSH_VERSION+"set"} = x"set" && NULLCMD=":" \ # 68| && (emulate sh) >$NULLDEV 2>&1 && emulate sh # 69| # Error: SHELLCHECK_WARNING (CWE-569): [#def2] /usr/bin/pdfroff:101:67: warning[SC2089]: Quotes/backslashes will be treated literally. Rewrite using set/"$@" or functions. # 99| # # 100| NO='' NOPROG="$CMD: installation problem: cannot find program" # 101|-> test "$CAT" = ":" && echo >&2 "$NOPROG 'cat' in PATH" && NO="$NO 'cat'" # 102| test "$GREP" = ":" && echo >&2 "$NOPROG 'grep' in PATH" && NO="$NO 'grep'" # 103| test "$GROFF" = ":" && echo >&2 "$NOPROG 'groff' in $GPATH" && NO="$NO 'groff'" Error: SHELLCHECK_WARNING (CWE-569): [#def3] /usr/bin/pdfroff:107:9: warning[SC2090]: Quotes/backslashes in this variable will not be respected. # 105| if test -n "$NO" # 106| then # 107|-> set $NO # 108| test $# -gt 1 && NO="s" IS="are" || NO='' IS="is" # 109| while test $# -gt 0 Error: SHELLCHECK_WARNING (CWE-456): [#def4] /usr/bin/pdfroff:133:40: warning[SC2121]: To assign a variable, use just 'var=value', no 'set ..'. # 131| if test -n "${PDFROFF_POSTPROCESSOR_COMMAND}" # 132| then # 133|-> GROFF_GHOSTSCRIPT_INTERPRETER=`set command ${PDFROFF_POSTPROCESSOR_COMMAND}; # 134| echo $2` # 135| fi Error: SHELLCHECK_WARNING (CWE-569): [#def5] /usr/bin/pdfroff:150:18: warning[SC2064]: Use single quotes, otherwise this expands now rather than when signalled. # 148| # so to clean up, we may simply purge it. # 149| # # 150|-> trap "rm -rf ${GROFF_TMPDIR}" 0 # 151| # # 152| else Error: SHELLCHECK_WARNING (CWE-569): [#def6] /usr/bin/pdfroff:159:17: warning[SC2064]: Use single quotes, otherwise this expands now rather than when signalled. # 157| # # 158| GROFF_TMPDIR=${TMPDIR} # 159|-> trap "rm -f ${GROFF_TMPDIR}/pdf$$.*" 0 # 160| fi # 161| # Error: SHELLCHECK_WARNING (CWE-569): [#def7] /usr/bin/pdfroff:159:36: warning[SC2064]: Use single quotes, otherwise this expands now rather than when signalled. # 157| # # 158| GROFF_TMPDIR=${TMPDIR} # 159|-> trap "rm -f ${GROFF_TMPDIR}/pdf$$.*" 0 # 160| fi # 161| # Error: SHELLCHECK_WARNING (CWE-398): [#def8] /usr/bin/pdfroff:168:23: warning[SC2172]: Trapping signals by number is not well defined. Prefer signal names. # 166| # here we trap SIGHUP, SIGINT, SIGQUIT, SIGPIPE and SIGTERM. # 167| # # 168|-> trap "exit 1" 1 2 3 13 15 # 169| # # 170| WRKFILE=${GROFF_TMPDIR}/pdf$$.tmp Error: SHELLCHECK_WARNING (CWE-482): [#def9] /usr/bin/pdfroff:207:34: error[SC1097]: Unexpected ==. For assignment, use =. For comparison, use [/[[. Or quote for literal string. # 205| # First identify, matching any abbreviation to its full form. # 206| # # 207|-> MATCH="" OPTNAME=`IFS==; set dummy $1; echo $2` # 208| for OPT in $LONGOPTS # 209| do Error: SHELLCHECK_WARNING (CWE-456): [#def10] /usr/bin/pdfroff:207:41: warning[SC2121]: To assign a variable, use just 'var=value', no 'set ..'. # 205| # First identify, matching any abbreviation to its full form. # 206| # # 207|-> MATCH="" OPTNAME=`IFS==; set dummy $1; echo $2` # 208| for OPT in $LONGOPTS # 209| do Error: SHELLCHECK_WARNING (CWE-456): [#def11] /usr/bin/pdfroff:302:16: warning[SC2209]: Use var=$(command) to assign output (or quote to assign string). # 300| # 301| --report-progress) # 302|-> SHOW_PROGRESS=echo # 303| ;; # 304| Error: SHELLCHECK_WARNING (CWE-456): [#def12] /usr/bin/pdfroff:374:16: warning[SC2121]: To assign a variable, use just 'var=value', no 'set ..'. # 372| -[dfFILmMnoPrTwW]) # 373| OPTNAME="$1" # 374|-> shift; set reparse "$OPTNAME$@" # 375| ;; # 376| # Error: SHELLCHECK_WARNING (CWE-138): [#def13] /usr/bin/pdfroff:374:33: error[SC2145]: Argument mixes string and array. Use * or separate argument. # 372| -[dfFILmMnoPrTwW]) # 373| OPTNAME="$1" # 374|-> shift; set reparse "$OPTNAME$@" # 375| ;; # 376| # Error: SHELLCHECK_WARNING (CWE-456): [#def14] /usr/bin/pdfroff:390:16: warning[SC2121]: To assign a variable, use just 'var=value', no 'set ..'. # 388| # '-h' and '-v' options redirect to their equivalent long forms ... # 389| # # 390|-> -h*) set redirect --help # 391| ;; # 392| # Error: SHELLCHECK_WARNING (CWE-456): [#def15] /usr/bin/pdfroff:393:23: warning[SC2121]: To assign a variable, use just 'var=value', no 'set ..'. # 391| ;; # 392| # # 393|-> -v*) shift; set redirect --version "$@" # 394| ;; # 395| # Error: SHELLCHECK_WARNING: [#def16] /usr/bin/pdfroff:425:45: warning[SC3037]: In POSIX sh, echo flags are undefined. # 423| # (Adapted from 'autoconf' code, as found in 'configure' scripts). # 424| # # 425|-> case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in # 426| *c*,*-n*) n='' c='' ;; # 427| *c*) n='-n' c='' ;; Error: SHELLCHECK_WARNING (CWE-569): [#def17] /usr/bin/pdfroff:445:5: warning[SC2188]: This redirection doesn't have a command. Move to its command (or use 'true' as no-op). # 443| if test -z "$DIFF" # 444| then # 445|-> >> $REFFILE # 446| echo kickstart > $REFCOPY # 447| test x${SHOW_PROGRESS+"set"} = x"set" && SAY=echo Error: SHELLCHECK_WARNING (CWE-456): [#def18] /usr/bin/pdfroff:447:46: warning[SC2209]: Use var=$(command) to assign output (or quote to assign string). # 445| >> $REFFILE # 446| echo kickstart > $REFCOPY # 447|-> test x${SHOW_PROGRESS+"set"} = x"set" && SAY=echo # 448| # # 449| # In order to correctly resolve 'pdfmark' references, Error: SHELLCHECK_WARNING (CWE-569): [#def19] /usr/bin/pdfroff:465:69: warning[SC2089]: Quotes/backslashes will be treated literally. Rewrite using set/"$@" or functions. # 463| fi # 464| DIFF=`searchpath diff "$PATH"` # 465|-> test "$AWK" = ":" && echo >&2 "$NOPROG 'awk' in PATH" && NO="$NO 'awk'" # 466| test "$DIFF" = ":" && echo >&2 "$NOPROG 'diff' in PATH" && NO="$NO 'diff'" # 467| if test -n "$NO" Error: SHELLCHECK_WARNING (CWE-569): [#def20] /usr/bin/pdfroff:469:11: warning[SC2090]: Quotes/backslashes in this variable will not be respected. # 467| if test -n "$NO" # 468| then # 469|-> set $NO # 470| SAY=":" AWK=":" DIFF=":" # 471| test $# -gt 1 && NO="s $1 and $2 are" || NO=" $1 is" Error: SHELLCHECK_WARNING (CWE-156): [#def21] /usr/bin/pdfroff:593:8: warning[SC2046]: Quote this to prevent word splitting. # 591| # as a result of parsing the document source ... # 592| # # 593|-> eval `$SED -n '/^ *pdfroff-option:set */s///p' $WRKFILE` # 594| # # 595| # ... (which is currently supported to enable "toc-relocation", Error: SHELLCHECK_WARNING (CWE-456): [#def22] /usr/bin/pdfroff:613:44: warning[SC2209]: Use var=$(command) to assign output (or quote to assign string). # 611| # of spurious messages associated with reference resolution). # 612| # # 613|-> test x${SHOW_PROGRESS+"set"} = x"set" && SAY=echo # 614| # # 615| # If a document cover style sheet is specified ... Error: SHELLCHECK_WARNING (CWE-398): [#def23] /usr/bin/pdfroff:651:35: warning[SC1078]: Did you forget to close this double quoted string? # 649| if test -z "$PDFROFF_POSTPROCESSOR_COMMAND" # 650| then # 651|-> PDFROFF_POSTPROCESSOR_COMMAND="$GS -dQUIET -dBATCH -dNOPAUSE -dSAFER # 652| -sDEVICE=pdfwrite -sOutputFile="${PDF_OUTPUT-"-"} # 653| Error: GCC_ANALYZER_WARNING: [#def24] groff-1.23.0/src/devices/xditview/xditview.c:367:5: warning[-Wanalyzer-overlapping-buffers]: overlapping buffers passed as arguments to ‘strcpy’ groff-1.23.0/src/devices/xditview/xditview.c:487:1: enter_function: entry to ‘RerasterizeAction’ groff-1.23.0/src/devices/xditview/xditview.c:499:5: call_function: calling ‘NewFile’ from ‘RerasterizeAction’ # 365| hadFile = 1; # 366| SelectPageNumber ("1"); # 367|-> strcpy (current_file_name, name); # 368| current_file = new_file; # 369| } Error: COMPILER_WARNING: [#def25] groff-1.23.0/src/libs/libdriver/printer.cpp:120:23: warning[-Wstringop-overflow=]: ‘__builtin_memset’ writing between 16 and 25769803768 bytes into a region of size 0 overflows the destination # 120 | font_table[i] = 0; # | ^ groff-1.23.0/src/libs/libdriver/printer.cpp:115:37: note: at offset [-8589934592, -8] into destination object of size [8, 17179869176] allocated by ‘operator new []’ # 115 | font_table = new font *[nfonts]; # | ^ # 118| font_table[i] = old_font_table[i]; # 119| for (i = old_nfonts; i < nfonts; i++) # 120|-> font_table[i] = 0; # 121| delete[] old_font_table; # 122| } Error: COMPILER_WARNING: [#def26] groff-1.23.0/src/libs/libdriver/printer.cpp: scope_hint: In member function ‘printer::load_font(int, char const*)’ groff-1.23.0/src/libs/libdriver/printer.cpp:120:23: warning[-Wstringop-overflow=]: ‘memset’ writing between 16 and 25769803768 bytes into a region of size 0 overflows the destination # 120 | font_table[i] = 0; # | ~~~~~~~~~~~~~~^~~ groff-1.23.0/src/libs/libdriver/printer.cpp:115:37: note: at offset [-8589934592, -8] into destination object of size [8, 17179869176] allocated by ‘operator new[](unsigned long)’ # 115 | font_table = new font *[nfonts]; # | ^ # 118| font_table[i] = old_font_table[i]; # 119| for (i = old_nfonts; i < nfonts; i++) # 120|-> font_table[i] = 0; # 121| delete[] old_font_table; # 122| } Error: COMPILER_WARNING (CWE-704): [#def27] groff-1.23.0/src/libs/libgroff/getopt.c: scope_hint: In function ‘_getopt_internal_r’ groff-1.23.0/src/libs/libgroff/getopt.c:777:18: warning[-Wdiscarded-qualifiers]: initialization discards ‘const’ qualifier from pointer target type # 777 | char *temp = strchr (optstring, c); # | ^~~~~~ # 775| { # 776| char c = *d->__nextchar++; # 777|-> char *temp = strchr (optstring, c); # 778| # 779| /* Increment 'optind' when we start to process its last character. */ Error: COMPILER_WARNING (CWE-704): [#def28] groff-1.23.0/src/libs/libgroff/getopt.c:777:18: warning[-Wdiscarded-qualifiers]: initialization discards ‘const’ qualifier from pointer target type # 775| { # 776| char c = *d->__nextchar++; # 777|-> char *temp = strchr (optstring, c); # 778| # 779| /* Increment 'optind' when we start to process its last character. */ Error: GCC_ANALYZER_WARNING (CWE-476): [#def29] groff-1.23.0/src/libs/libgroff/getopt.c:907:46: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘p’ groff-1.23.0/src/libs/libgroff/getopt.c:1166:1: enter_function: entry to ‘groff_getopt’ groff-1.23.0/src/libs/libgroff/getopt.c:1168:10: call_function: calling ‘_getopt_internal’ from ‘groff_getopt’ # 905| /* Test all long options for either exact match # 906| or abbreviated matches. */ # 907|-> for (p = longopts, option_index = 0; p->name; p++, option_index++) # 908| if (!strncmp (p->name, d->__nextchar, nameend - d->__nextchar)) # 909| { Error: CPPCHECK_WARNING (CWE-476): [#def30] groff-1.23.0/src/libs/libgroff/glyphuni.cpp:31: warning[nullPointerOutOfMemory]: If memory allocation fails, then there is a possible null pointer dereference: temp # 29| # 30| declare_ptable(glyph_to_unicode) # 31|-> implement_ptable(glyph_to_unicode) # 32| # 33| PTABLE(glyph_to_unicode) glyph_to_unicode_table; Error: COMPILER_WARNING (CWE-595): [#def31] groff-1.23.0/src/preproc/refer/ref.cpp: scope_hint: In function ‘int same_reference(const reference&, const reference&)’ groff-1.23.0/src/preproc/refer/ref.cpp:539:24: warning[-Warray-compare]: comparison between two arrays is deprecated in C++20 # 539 | if (r1.field_index != r2.field_index) # | ~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~ groff-1.23.0/src/preproc/refer/ref.cpp:539:24: note: use unary ‘+’ which decays operands to pointers or ‘&(r1.reference::field_index)[0] != &(r2.reference::field_index)[0]’ to compare the addresses # 537| int i = 0; # 538| for (i = 0; i < 256; i++) # 539|-> if (r1.field_index != r2.field_index) # 540| return 0; # 541| for (i = 0; i < r1.nfields; i++)
| analyzer-version-clippy | 1.97.1 |
| analyzer-version-cppcheck | 2.21.1 |
| analyzer-version-gcc | 16.1.1 |
| analyzer-version-gcc-analyzer | 16.1.1 |
| analyzer-version-shellcheck | 0.11.0 |
| analyzer-version-unicontrol | 0.0.2 |
| diffbase-analyzer-version-clippy | 1.97.1 |
| diffbase-analyzer-version-cppcheck | 2.21.1 |
| diffbase-analyzer-version-gcc | 16.1.1 |
| diffbase-analyzer-version-gcc-analyzer | 16.1.1 |
| diffbase-analyzer-version-shellcheck | 0.11.0 |
| diffbase-analyzer-version-unicontrol | 0.0.2 |
| diffbase-enabled-plugins | clippy, cppcheck, gcc, shellcheck, unicontrol |
| diffbase-exit-code | 0 |
| diffbase-host | ip-172-16-1-98.us-west-2.compute.internal |
| diffbase-known-false-positives | /usr/share/csmock/known-false-positives.js |
| diffbase-known-false-positives-rpm | known-false-positives-0.0.0.20260524.213755.g3c6d0be.main-1.el9.noarch |
| diffbase-mock-config | fedora-rawhide-x86_64 |
| diffbase-project-name | groff-1.24.1-2.fc45 |
| diffbase-store-results-to | /tmp/tmpvguz48v2/groff-1.24.1-2.fc45.tar.xz |
| diffbase-time-created | 2026-08-03 14:47:49 |
| diffbase-time-finished | 2026-08-03 14:50:45 |
| diffbase-tool | csmock |
| diffbase-tool-args | '/usr/bin/csmock' '-r' 'fedora-rawhide-x86_64' '-t' 'gcc,clippy,unicontrol,shellcheck,cppcheck' '-o' '/tmp/tmpvguz48v2/groff-1.24.1-2.fc45.tar.xz' '--gcc-analyze' '--unicontrol-notests' '--unicontrol-bidi-only' '--install' 'pam' '--gcc-analyzer-bin=/usr/bin/gcc' '/tmp/tmpvguz48v2/groff-1.24.1-2.fc45.src.rpm' |
| diffbase-tool-version | csmock-3.8.7.HEAD-1.el9 |
| enabled-plugins | clippy, cppcheck, gcc, shellcheck, unicontrol |
| exit-code | 0 |
| host | ip-172-16-1-98.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.20260524.213755.g3c6d0be.main-1.el9.noarch |
| mock-config | fedora-rawhide-x86_64 |
| project-name | groff-1.23.0-12.fc44 |
| store-results-to | /tmp/tmphdgqdczv/groff-1.23.0-12.fc44.tar.xz |
| time-created | 2026-08-03 14:44:23 |
| time-finished | 2026-08-03 14:47:24 |
| title | Fixed findings |
| tool | csmock |
| tool-args | '/usr/bin/csmock' '-r' 'fedora-rawhide-x86_64' '-t' 'gcc,clippy,unicontrol,shellcheck,cppcheck' '-o' '/tmp/tmphdgqdczv/groff-1.23.0-12.fc44.tar.xz' '--gcc-analyze' '--unicontrol-notests' '--unicontrol-bidi-only' '--install' 'pam' '--gcc-analyzer-bin=/usr/bin/gcc' '/tmp/tmphdgqdczv/groff-1.23.0-12.fc44.src.rpm' |
| tool-version | csmock-3.8.7.HEAD-1.el9 |