Re: Who takes care of a crashing process?
site_archiver@lists.apple.com Delivered-To: darwin-dev@lists.apple.com On Sep 22, 2004, at 9:36, stephane sudre wrote: On Sep 22, 2004, at 6:08 PM, Justin Walker wrote: On Sep 22, 2004, at 8:13, Stephane Sudre wrote: Stupid question probably: When a process is properly exited, exit is called in the Kernel. When a process crashes, exit is not called. Well, I've patched the SYS_exit syscall and ran this program: int main(...) { unsigned long * ohlala=NULL; *ohlala=NULL; } If this doesn't clarify things, ask. Cheers, Justin _______________________________________________ Do not post admin requests to the list. They will be ignored. Darwin-dev mailing list (Darwin-dev@lists.apple.com) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/darwin-dev/site_archiver%40lists.appl... Is there a specific syscall called when a process crash? Are you sure that exit() in the kernel is not called? If this were not the case, we'd be leaking file entries, memory, and other resources. I have not seen an exit call. Ah. Once your program has crashed (e.g., with a memory fault/bus error), code in its address space is no longer eligible for execution. Despite that, however, the kernel's exit() procedure *is* called. But maybe it's because there's no exit at the end of the code. The previous answer is confusing me right now. -- Justin C. Walker, Curmudgeon-At-Large * Institute for General Semantics | "Weaseling out of things is what | separates us from the animals. | Well, except the weasel." | - Homer J Simpson *--------------------------------------*-------------------------------* This email sent to site_archiver@lists.apple.com
participants (1)
-
Justin Walker