Fix the null reference vulnerability

This commit is contained in:
qiuweibin 2025-03-11 03:38:50 +00:00
parent db4a3005e3
commit 02f3727d87
1 changed files with 4 additions and 0 deletions

View File

@ -4444,6 +4444,8 @@ Rwr_ManAddTimeCuts( pManRwr, Abc_Clock() - clk );
// skip persistant nodes
if ( Abc_NodeIsPersistant(pNode) )
{
if (!(pGain_res && pGain_ref && pGain_rwr))
return 0;
fprintf(fpt, "%d, %s, %d\n", pNode->Id, "None" , -99);
Vec_IntPush((*pGain_res), -99);
Vec_IntPush((*pGain_ref), -99);
@ -4453,6 +4455,8 @@ Rwr_ManAddTimeCuts( pManRwr, Abc_Clock() - clk );
// skip the nodes with many fanouts
if ( Abc_ObjFanoutNum(pNode) > 1000 )
{
if (!(pGain_res && pGain_ref && pGain_rwr))
return 0;
fprintf(fpt, "%d, %s, %d\n", pNode->Id,"None", -99);
Vec_IntPush((*pGain_res), -99);
Vec_IntPush((*pGain_ref), -99);