deleting pointer recursion