http://llvm.org/bugs/show_bug.cgi?id=8831
Summary: -Wformat-security: Cannot pass 0 as format-string
Product: clang
Version: 2.8
Platform: PC
OS/Version: All
Status: NEW
Severity: normal
Priority: P
Component: -New Bugs
AssignedTo: [email protected]
ReportedBy: [email protected]
CC: [email protected]
Created an attachment (id=5912)
--> (http://llvm.org/bugs/attachment.cgi?id=5912)
C source file
In the following file, Clang makes a warning for something on which GCC does
not. Since there is a specific attribute to forbid null pointers as arguments,
it seems to me that the best behavior here is that of GCC.
clang -Wall format.cc -o foo -c
format.cc:7:12: warning: format string is not a string literal (potentially
insecure) [-Wformat-security]
myprintf(0);
^
1 warning generated.
--
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