#include <iostream>
func(void *ptr)
{
*ptr = NULL;
}
int main()
{
void *ptr = (int*)malloc(sizeof(int));
func(ptr);
return 0;
}
Can Some one Help me in Resolving this. I want to assign NULL to this Pointer. Do Not make any changes in Main().