[clang] [analyzer] Fix null-pointer dereference in PthreadLockChecker (PR #210912)

Balázs Benics via cfe-commits cfe-commits at lists.llvm.org
Mon Jul 27 06:23:17 PDT 2026


================
@@ -20,10 +20,47 @@ namespace ento {
 
 RangedConstraintManager::~RangedConstraintManager() {}
 
+// Is `Assumption` (i.e. "the condition is non-zero") consistent with a symbol
+// that simplified to the concrete integer `V`? Mirrors the nonloc::ConcreteInt
+// handling in SimpleConstraintManager::assumeAux.
+static bool isConcreteFeasible(const llvm::APSInt &V, bool Assumption) {
----------------
steakhal wrote:

This function is only used from context where the result is negated.
This suggests to me that phrasing this as `isConcreteInfeasible` would be a better match.

https://github.com/llvm/llvm-project/pull/210912


More information about the cfe-commits mailing list