Fixed #6533 (library: alloc/dealloc doesn't work when function declaration is seen)

This commit is contained in:
Daniel Marjamäki 2015-03-07 09:43:56 +01:00
parent 143c5d4875
commit 87ebeb3f65
1 changed files with 2 additions and 2 deletions

View File

@ -71,12 +71,12 @@ public:
/** get allocation id for function */
int alloc(const Token *tok) const {
return tok->function() ? 0 : getid(_alloc, tok->str());
return isNotLibraryFunction(tok) && argumentChecks.find(tok->str()) != argumentChecks.end() ? 0 : getid(_alloc, tok->str());
}
/** get deallocation id for function */
int dealloc(const Token *tok) const {
return tok->function() ? 0 : getid(_dealloc, tok->str());
return isNotLibraryFunction(tok) && argumentChecks.find(tok->str()) != argumentChecks.end() ? 0 : getid(_dealloc, tok->str());
}
/** get deallocation id for function by name */