is called on a pointer that does not get its value directly from malloc.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@93706
91177308-0d34-0410-b5e6-
96231b3b80d8
assert(Sym);
const RefState *RS = state->get<RegionState>(Sym);
- assert(RS);
+
+ // If the symbol has not been tracked, return. This is possible when free() is
+ // called on a pointer that does not get its pointee directly from malloc().
+ // Full support of this requires inter-procedural analysis.
+ if (!RS)
+ return state;
// Check double free.
if (RS->isReleased()) {