How to create a process that is not a child of it's creating process?
问题 I have two processes, A and B. At some point A creates B. After B is created, if A's process tree is killed, I want B to still be around. I am using CreateProcess() to create B, and I can't seem to find any way to make it create the process without it being a child. Same thing with ShellExecuteEx(), but I am probably missing some flag. Does anyone know what I could use to do this? EDIT: I forgot to mention that both processes need a HANDLE or process ID to the other 回答1: You can try that