Dangling points to memory locations which actually doesnt exitsvoid main(){ int *p,*q; p = new int() q= p; delete p; //q will be dangling point in this case, as it is pointing to memory which doesnt exist}
Post a Comment
1 comment:
Dangling points to memory locations which actually doesnt exits
void main()
{
int *p,*q;
p = new int()
q= p;
delete p;
//q will be dangling point in this case, as it is pointing to memory which doesnt exist
}
Post a Comment