Fix undefined behaviors caught by ubsan
This fixes a couple of integer overflows in parsing as well as removes the construction of a null reference that never got dereferenced. This also initializes the bool members in TCall Finally, this adds a UBSAN run alongside ASAN and TSAN in CI.
This commit is contained in:
parent
702026e3f5
commit
48eaea60b8
5 changed files with 14 additions and 5 deletions
|
|
@ -99,7 +99,8 @@ private:
|
|||
// A "call" is a pair: <caller, callee>.
|
||||
// There can be duplicates. General assumption is the list is small.
|
||||
struct TCall {
|
||||
TCall(const TString& pCaller, const TString& pCallee) : caller(pCaller), callee(pCallee) { }
|
||||
TCall(const TString& pCaller, const TString& pCallee)
|
||||
: caller(pCaller), callee(pCallee), visited(false), currentPath(false), errorGiven(false) { }
|
||||
TString caller;
|
||||
TString callee;
|
||||
bool visited;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue