http://llvm.org/bugs/show_bug.cgi?id=20929
Bug ID: 20929
Summary: False positive from security.ReturnPtrRange on
std::end(T(&array)[N])
Product: clang
Version: trunk
Hardware: PC
OS: MacOS X
Status: NEW
Severity: normal
Priority: P
Component: Static Analyzer
Assignee: [email protected]
Reporter: [email protected]
CC: [email protected]
Classification: Unclassified
ReturnPtrRange doesn't like the past-the-end pointer returned by std::end:
#include <iterator>
void foo() {
int arr[5] = {};
std::end(arr);
}
which gets me a:
warning: Returned pointer value points outside the original object
(potential buffer overflow) [clang-analyzer-alpha.security.ReturnPtrRange]
in the implementation of std::end(T(&array)[N]) ("return __array + _Np;")
--
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