"When I scan my code with SI_Scan in my IDE,I found I misdescription for nullpoint check.It reported a dereferenceAfterCheck error to me,but in fact,the code is correct in my opinion.
The code is :
if (!(Mgr::GetInstance()->GetResDataByKey(pCharacter, dwCharacterID) < 0 ||pCharacter== NULL))
{
iProfession = pCharacter ->bProfession;
}
I think here is the simplified scence for the matching error:
“if(!p || p->xx)”
"
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
"When I scan my code with SI_Scan in my IDE,I found I misdescription for nullpoint check.It reported a dereferenceAfterCheck error to me,but in fact,the code is correct in my opinion.
The code is :
if (!(Mgr::GetInstance()->GetResDataByKey(pCharacter, dwCharacterID) < 0 ||pCharacter== NULL))
{
iProfession = pCharacter ->bProfession;
}
I think here is the simplified scence for the matching error:
“if(!p || p->xx)”
"