[llvm-bugs] [Bug 41185] New: Assertion failure in WalkAST::checkDeprecatedOrUnsafeBufferHandling(...): ArgIndex != UNKNOWN_CALL && "Unsupported function"

via llvm-bugs llvm-bugs at lists.llvm.org
Thu Mar 21 09:24:16 PDT 2019


https://bugs.llvm.org/show_bug.cgi?id=41185

            Bug ID: 41185
           Summary: Assertion failure in
                    WalkAST::checkDeprecatedOrUnsafeBufferHandling(...):
                    ArgIndex != UNKNOWN_CALL && "Unsupported function"
           Product: clang
           Version: unspecified
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: Static Analyzer
          Assignee: noqnoqneo at gmail.com
          Reporter: alexfh at google.com
                CC: dcoughlin at apple.com, llvm-bugs at lists.llvm.org

$ cat t.c
a() { __builtin_strncpy(a, "", 6); }
$ clang-tidy -checks="-*,clang-analyzer*" t.c --
assert.h assertion failed at
llvm/tools/clang/lib/StaticAnalyzer/Checkers/CheckSecuritySyntaxOnly.cpp:753 in
void (anonymous
namespace)::WalkAST::checkDeprecatedOrUnsafeBufferHandling(const
clang::CallExpr *, const clang::FunctionDecl *): ArgIndex != UNKNOWN_CALL &&
"Unsupported function"
    @     0x55b9b02165c6  __assert_fail
    @     0x55b9ae6ce98c  (anonymous
namespace)::WalkAST::checkDeprecatedOrUnsafeBufferHandling()
    @     0x55b9ae6cb313  (anonymous namespace)::WalkAST::VisitCallExpr()
    @     0x55b9ae6cac7c  (anonymous namespace)::WalkAST::VisitCompoundStmt()
    @     0x55b9ae6ca3ff  clang::ento::check::ASTCodeBody::_checkBody<>()
    @     0x55b9ae8e50b2  clang::ento::CheckerManager::runCheckersOnASTBody()
    @     0x55b9ae65aedd  (anonymous namespace)::AnalysisConsumer::HandleCode()
    @     0x55b9ae646784  clang::RecursiveASTVisitor<>::TraverseDecl()
    @     0x55b9ae644844  (anonymous
namespace)::AnalysisConsumer::HandleTranslationUnit()
    @     0x55b9aec5d43c  clang::MultiplexConsumer::HandleTranslationUnit()
    @     0x55b9aedc7e54  clang::ParseAST()

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20190321/06bf570d/attachment.html>


More information about the llvm-bugs mailing list