Re: Any tool that tells COM dependencies of a DLL?
- From: "mysteron" <acornatom66@xxxxxxxxx>
- Date: Wed, 22 Feb 2006 10:19:39 -0800
um - that's not what i see every day in the shell.. i see the shell load my
com dll breifly.. use it.. and release it.. i then see my DLL_PROCESS_DETACH
called and i'm gawn... maybe i'm misunderstanding something but i'm telling
you what i see.. i don't see the DLL get loaded and held onto... maybe
things are different in vista..
"Alexander Nickolov" <agnickolov@xxxxxxxx> wrote in message
news:eR4aJo9NGHA.2668@xxxxxxxxxxxxxxxxxxxxxxx
Actually that's what Igor was trying to tell you - the DLL never
gets unloaded even if the client never needs it anymore. It _can_
be unloaded in theory, but it never is in practice.
BTW, did you find COMSpy not helpful? I haven't used it
myself I admit...
--
=====================================
Alexander Nickolov
Microsoft MVP [VC], MCSD
email: agnickolov@xxxxxxxx
MVP VC FAQ: http://www.mvps.org/vcfaq
=====================================
"mysteron" <acornatom66@xxxxxxxxx> wrote in message
news:u5shdP2NGHA.1028@xxxxxxxxxxxxxxxxxxxxxxx
ok lets not nit pick here :) the scenario i was talking about is where
the client does a single cocreate, uses the interface and releases... all
in a short period of time.. the DLL gets unloaded shortly afterwards.. so
my point was that this loading/unloading is very dynamic .. and not
something that is easily followed just by keeping your eyes glued to
process explorer... also it might well happen in less time than the
refresh rate of that program, in which case you'd certainly see nothing
...
I see this behavior all the time when programming the windows vista
shell... dll's certainly *do* unload before the shell terminates... well
before...
"Igor Tandetnik" <itandetnik@xxxxxxxx> wrote in message
news:uMOeWL2NGHA.2696@xxxxxxxxxxxxxxxxxxxxxxx
"mysteron" <acornatom66@xxxxxxxxx> wrote in message
news:%23lQATo1NGHA.3064@xxxxxxxxxxxxxxxxxxxx
Also, even if the COM
object lives in a DLL.. that DLL will only be loaded into the process
space for the lifetime of the IUnkown pointer pased back from
cocreateinstance..
That's not true. Once loaded, COM DLLs are usually not unloaded until
the process is terminated, even when there are no outstanding
references. In principle, one can unload them explicitly by calling
CoFreeUnusedLibraries, but many people claim this function is actually a
no-op on modern OS versions (Win2K and above if I recall correctly).
--
With best wishes,
Igor Tandetnik
With sufficient thrust, pigs fly just fine. However, this is not
necessarily a good idea. It is hard to be sure where they are going to
land, and it could be dangerous sitting under them as they fly
overhead. -- RFC 1925
.
- References:
- RE: Any tool that tells COM dependencies of a DLL?
- From: "TerryFei"
- Re: Any tool that tells COM dependencies of a DLL?
- From: Igor Tandetnik
- Re: Any tool that tells COM dependencies of a DLL?
- From: mysteron
- Re: Any tool that tells COM dependencies of a DLL?
- From: Alexander Nickolov
- RE: Any tool that tells COM dependencies of a DLL?
- Prev by Date: Re: proxy-stub question
- Next by Date: Re: proxy-stub question
- Previous by thread: Re: Any tool that tells COM dependencies of a DLL?
- Next by thread: Problem with IApcProject.SaveCompleted
- Index(es):
Relevant Pages
|