7 ms·
If you are transferring ownership, you would do p2 = p1; p1 = NULL; However if you are intentionally doing multiple ownership, then yes you can still have
by btrask 6y ago
If you are transferring ownership, you would do
p2 = p1; p1 = NULL;
However if you are intentionally doing multiple ownership, then yes you can still have problems.