[LLVMbugs] [Bug 14461] New: false positive: uninitialised/garbage values
bugzilla-daemon at llvm.org
bugzilla-daemon at llvm.org
Thu Nov 29 20:53:12 PST 2012
http://llvm.org/bugs/show_bug.cgi?id=14461
Bug #: 14461
Summary: false positive: uninitialised/garbage values
Product: clang
Version: unspecified
Platform: Macintosh
OS/Version: MacOS X
Status: NEW
Severity: normal
Priority: P
Component: Static Analyzer
AssignedTo: kremenek at apple.com
ReportedBy: marka at isc.org
CC: llvmbugs at cs.uiuc.edu
Classification: Unclassified
Created attachment 9612
--> http://llvm.org/bugs/attachment.cgi?id=9612
pre-processed code.
Multiple versions of clang.
Apple clang version 4.1 (tags/Apple/clang-421.11.66) (based on LLVM 3.1svn)
Target: x86_64-apple-darwin12.2.0
Thread model: posix
clang version 3.1 (branches/release_31)
Target: i386-portbld-freebsd8.3
Thread model: posix
The static analyser fails to remember that it set response to 0 for the
analysis then proceeds to complain about code that will not be reached when
response is 0.
clang --analyze tsig.preprocessed.c
In file included from tsig.c:1:
tsig.c:1337:4: warning: Function call argument is an uninitialized value
isc__buffer_putuint16(&databuf, querytsig.siglen);
^ ~~~~~~~~~~~~~~~~
tsig.c:1075:26: warning: The right operand of '<' is a garbage value
if (response && bytes < querytsig.siglen)
^ ~~~~~~~~~~~~~~~~
tsig.c:1024:20: warning: Assigned value is garbage or undefined
tsig.timesigned = querytsig.timesigned;
^ ~~~~~~~~~~~~~~~~~~~~
--
Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
More information about the llvm-bugs
mailing list