[PATCH] D15810: [analyzer] Handle another Android assert function.

Yury Gribov via llvm-commits llvm-commits at lists.llvm.org
Tue Dec 29 07:51:25 PST 2015


ygribov created this revision.
ygribov added reviewers: zaks.anna, dcoughlin.
ygribov added a subscriber: llvm-commits.
ygribov set the repository for this revision to rL LLVM.
Herald added subscribers: danalbert, tberghammer.

Android's assert can call both __assert and __assert2 functions under the cover but NoReturn does not handle the latter. This patch fixes this.

Repository:
  rL LLVM

http://reviews.llvm.org/D15810

Files:
  lib/StaticAnalyzer/Checkers/NoReturnFunctionChecker.cpp

Index: lib/StaticAnalyzer/Checkers/NoReturnFunctionChecker.cpp
===================================================================
--- lib/StaticAnalyzer/Checkers/NoReturnFunctionChecker.cpp
+++ lib/StaticAnalyzer/Checkers/NoReturnFunctionChecker.cpp
@@ -66,6 +66,7 @@
             .Case("assfail", true)
             .Case("db_error", true)
             .Case("__assert", true)
+            .Case("__assert2", true)
             // For the purpose of static analysis, we do not care that
             //  this MSVC function will return if the user decides to continue.
             .Case("_wassert", true)


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D15810.43737.patch
Type: text/x-patch
Size: 607 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20151229/e8312535/attachment-0001.bin>


More information about the llvm-commits mailing list