uriparser-0.9.9-1.fc44

List of Findings

Error: COMPILER_WARNING: [#def1] [important]
uriparser-0.9.9/redhat-linux-build/CMakeFiles/CMakeScratch/TryCompile-yMsfTK/CheckSymbolExists.c:8:19: error[error]: ‘wprintf’ undeclared (first use in this function)

Error: GCC_ANALYZER_WARNING (CWE-476): [#def2]
uriparser-0.9.9/src/UriQuery.c:216:17: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘charsRequired’
uriparser-0.9.9/src/UriQuery.c:124:5: enter_function: entry to ‘uriComposeQueryExA’
uriparser-0.9.9/src/UriQuery.c:135:16: call_function: calling ‘uriComposeQueryEngineA’ from ‘uriComposeQueryExA’
#  214|   	/* Subtract terminator */
#  215|   	if (dest == NULL) {
#  216|-> 		*charsRequired = 0;
#  217|   	} else {
#  218|   		maxChars--;

Error: CPPCHECK_WARNING (CWE-476): [#def3]
uriparser-0.9.9/test/test.cpp:2357: warning[nullPointerOutOfMemory]: If memory allocation fails, then there is a possible null pointer dereference: uriFirst
# 2355|   	UriUriA uri;
# 2356|   	char * uriFirst = strdup(uriString);
# 2357|-> 	const size_t uriLen = strlen(uriFirst);
# 2358|   	char * uriAfterLast = uriFirst + uriLen;
# 2359|   

Error: CPPCHECK_WARNING (CWE-682): [#def4]
uriparser-0.9.9/test/test.cpp:2358: error[nullPointerArithmeticOutOfMemory]: If memory allocation fails: pointer addition with NULL pointer.
# 2356|   	char * uriFirst = strdup(uriString);
# 2357|   	const size_t uriLen = strlen(uriFirst);
# 2358|-> 	char * uriAfterLast = uriFirst + uriLen;
# 2359|   
# 2360|   	EXPECT_EQ(uriParseSingleUriExA(&uri, uriFirst, uriAfterLast, NULL), URI_SUCCESS);

Scan Properties

analyzer-version-clippy1.90.0
analyzer-version-cppcheck2.18.3
analyzer-version-gcc15.2.1
analyzer-version-gcc-analyzer16.0.0
analyzer-version-shellcheck0.11.0
analyzer-version-unicontrol0.0.2
enabled-pluginsclippy, cppcheck, gcc, shellcheck, unicontrol
exit-code0
hostip-172-16-1-40.us-west-2.compute.internal
known-false-positives/usr/share/csmock/known-false-positives.js
known-false-positives-rpmknown-false-positives-0.0.0.20250521.132812.g8eff701.main-1.el9.noarch
mock-configfedora-rawhide-gcc-latest-x86_64
project-nameuriparser-0.9.9-1.fc44
store-results-to/tmp/tmpvi5qapcy/uriparser-0.9.9-1.fc44.tar.xz
time-created2025-10-28 20:40:21
time-finished2025-10-28 20:42:26
toolcsmock
tool-args'/usr/bin/csmock' '-r' 'fedora-rawhide-gcc-latest-x86_64' '-t' 'gcc,cppcheck,shellcheck,clippy,unicontrol' '-o' '/tmp/tmpvi5qapcy/uriparser-0.9.9-1.fc44.tar.xz' '--gcc-analyze' '--unicontrol-notests' '--unicontrol-bidi-only' '--install' 'pam' '--install=gcc-latest' '--gcc-analyzer-bin=/opt/gcc-latest/bin/gcc' '/tmp/tmpvi5qapcy/uriparser-0.9.9-1.fc44.src.rpm'
tool-versioncsmock-3.8.3.20251027.143044.ge6b947b-1.el9