here i have tried to catch the write access violation but it doesn't work. I have tried some other ways but none worked for me. can you please explain.
int main(){ int *pint = new int();
delete pint;
try
{
*pint = 100;
}
catch (...)
{
cout << "this is the one " << endl;
}
}
Aucun commentaire:
Enregistrer un commentaire