Application domains allow applications to be unloaded separately. My question is how unloading an apllication can crash another application. Any example?
A:
In theory, App Domains are completely isolated from each other (even though you may run several App Domains in one process, they act as separate processes), so this shouldn't be possible.
Are you asking theoretically, or are you actually experiencing crashes?
Daniel Magliola
2010-10-12 13:06:19
No I am asking is there a possibility of a crash if we do not use app domains. If yes can someone give an example?
Nadeem
2010-10-12 13:09:16
Ah, I see. So the question is not whether "unloading" an app can cause a crash. Yes, you can cause a crash in an application if you use unsafe C#, if you call COM or Win32 APIs, for example. I'm not exactly sure of whether you're talking about App Domains in IIS (and thus, web apps), or regular apps, there are millions of way to crash, really
Daniel Magliola
2010-10-12 13:12:02
A:
I assume you mean AppDomain when saying Application.
Pure managed code should unload correctly (but not all finalizers might execute)
But buggy native inter-op can of course still crash the process.
CodeInChaos
2010-10-12 13:10:12