zombie to exist after termination of main prog.
main()
{
pid_t child;
child=fork();
if(child > 0)
{sleep(60);
}
else
{exit(0);
}
}
the above code will create zombie process,which will be adopted by init as soon as parent process will dies.Can any one gimme a code or an algorithm to keep this zombie process alive even after its parent dies...i.e to stop init from adopting it after the termination of main programme
anil chowdhury
|