<html>
<head>
<base href="https://bugs.llvm.org/">
</head>
<body><table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Bug ID</th>
<td><a class="bz_bug_link
bz_status_NEW "
title="NEW - Assertion failure in CStringChecker::IsFirstBufInBound"
href="https://bugs.llvm.org/show_bug.cgi?id=34799">34799</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>Assertion failure in CStringChecker::IsFirstBufInBound
</td>
</tr>
<tr>
<th>Product</th>
<td>clang
</td>
</tr>
<tr>
<th>Version</th>
<td>trunk
</td>
</tr>
<tr>
<th>Hardware</th>
<td>PC
</td>
</tr>
<tr>
<th>OS</th>
<td>Linux
</td>
</tr>
<tr>
<th>Status</th>
<td>NEW
</td>
</tr>
<tr>
<th>Severity</th>
<td>enhancement
</td>
</tr>
<tr>
<th>Priority</th>
<td>P
</td>
</tr>
<tr>
<th>Component</th>
<td>Static Analyzer
</td>
</tr>
<tr>
<th>Assignee</th>
<td>noqnoqneo@gmail.com
</td>
</tr>
<tr>
<th>Reporter</th>
<td>alexfh@google.com
</td>
</tr>
<tr>
<th>CC</th>
<td>dcoughlin@apple.com, ganna@apple.com, kremenek@apple.com, llvm-bugs@lists.llvm.org
</td>
</tr></table>
<p>
<div>
<pre>$ cat test-CStringChecker__IsFirstBufInBound.cc
void memset(void *, int, long);
class a {
void b();
int c;
char e[];
};
void a::b() {
a *d = new a;
*d = *this;
memset(e, 0, d->c);
}
$ clang-tidy -checks=-*,clang-analyzer-unix.cstring*
test-CStringChecker__IsFirstBufInBound.cc -- -std=c++11
assertion failed at
llvm/tools/clang/include/clang/StaticAnalyzer/Core/PathSensitive/SVals.h:93 in
T clang::ento::SVal::castAs() const [T = clang::ento::NonLoc]: T::isKind(*this)
@ 0x52c61ca __assert_fail
@ 0x169bd1a clang::ento::SVal::castAs<>()
@ 0x1b3bed4 (anonymous
namespace)::CStringChecker::IsFirstBufInBound()
@ 0x1b3afa4 (anonymous
namespace)::CStringChecker::InvalidateBuffer()
@ 0x1b373ae (anonymous namespace)::CStringChecker::evalMemset()
@ 0x1b36174 (anonymous namespace)::CStringChecker::evalCall()
@ 0x1b34f30 clang::ento::eval::Call::_evalCall<>()
@ 0x1c554b2 clang::ento::CheckerFn<>::operator()()
@ 0x1c5262e clang::ento::CheckerManager::runCheckersForEvalCall()
@ 0x1cb62f9 clang::ento::ExprEngine::evalCall()
@ 0x1cb61bc clang::ento::ExprEngine::VisitCallExpr()
@ 0x1c6ef27 clang::ento::ExprEngine::Visit()
@ 0x1c6bf01 clang::ento::ExprEngine::ProcessStmt()
@ 0x1c6bbba clang::ento::ExprEngine::processCFGElement()
@ 0x1c9a206 clang::ento::CoreEngine::HandlePostStmt()
@ 0x1c99b06 clang::ento::CoreEngine::dispatchWorkItem()
@ 0x1c99668 clang::ento::CoreEngine::ExecuteWorkList()
@ 0xf8c365 clang::ento::ExprEngine::ExecuteWorkList()
@ 0xf33992 (anonymous
namespace)::AnalysisConsumer::ActionExprEngine()
@ 0xf33751 (anonymous
namespace)::AnalysisConsumer::RunPathSensitiveChecks()
@ 0xf33415 (anonymous namespace)::AnalysisConsumer::HandleCode()
@ 0xf26ab3 (anonymous
namespace)::AnalysisConsumer::HandleDeclsCallGraph()
@ 0xf24d37 (anonymous
namespace)::AnalysisConsumer::HandleTranslationUnit()
@ 0x135bf7e clang::MultiplexConsumer::HandleTranslationUnit()
@ 0x1db73d6 clang::ParseAST()
@ 0x134982a clang::ASTFrontendAction::ExecuteAction()
@ 0x13492c0 clang::FrontendAction::Execute()
@ 0x115f4e2 clang::CompilerInstance::ExecuteAction()
@ 0x1028652
clang::tooling::FrontendActionFactory::runInvocation()</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are on the CC list for the bug.</li>
</ul>
</body>
</html>