tags:

views:

30

answers:

2

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
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
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
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