http://llvm.org/bugs/show_bug.cgi?id=12186
Bug #: 12186
Summary: AsmStmt output parameters are not checked for nullptr
derefs
Product: clang
Version: trunk
Platform: PC
OS/Version: All
Status: NEW
Severity: enhancement
Priority: P
Component: Static Analyzer
AssignedTo: [email protected]
ReportedBy: [email protected]
CC: [email protected]
Classification: Unclassified
Autotest nullptr.cpp contains the following function:
void zoo2() {
int **a = 0;
int **b = 0;
asm ("nop"
:"=a"(*a)
:"0"(*b) // expected-warning{{Dereference of null pointer}}
);
}
First "a" is initialised to null, and in the asm statmement "a" is dereferenced
on the output parameter position. No warning is produced, while dereferencing
the input parameter "b" does give a warning.
--
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.
_______________________________________________
LLVMbugs mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/llvmbugs