Outlook 2007 freezing when out-proc COM (called by add-in) exits

  • Thread starter Thread starter Mark McGinty
  • Start date Start date
M

Mark McGinty

Greets,

I have an addin, written in VB6, that calls an out-proc COM server (to
process a queue, though this is not important.) Before it exits the COM
server fires an event, following which the addin sets the object variable
(for the COM server) to Nothing. After the addin returns from that event,
the COM server releases its object references and then calls the ExitProcess
API.

I added the call to ExitProcess to support Vista, because without it Vista
"detected" a hung process, which made for a very annoying UI experience
every time the COM server was called. (The call to ExitProcess also makes
debugging the COM server interesting, because it causes the VB6 IDE to exit
its process as well, though this, too, is not important.)

All of the above works fine up to and including Outlook 2003, but in Outlook
2007, if an inspector is open when the COM server exits, Outlook freezes.
(I can tell it is at exactly this point from debugging output generated by
the COM server and the addin.) Task man shows CPU usage for Outlook's
process at 99% when this occurs.

Has anyone read anything, about changes in Outlook 2007, that might be
relevant?


TIA,
Mark
 
Update: The freeze-up may not necessarily be associated with the COM
server's exit -- it happened to me that way twice, but then failed to happen
across a dozen creation/destruction cycles for that object. It also
happened while no instances of the COM server object existed.

The only thing common to all occurrences of this freeze-up is that, each
time when it happened, I was typing in an email inspector, while some level
of background processing was ongoing. Once Outlook hangs, its memory
allocation and handle counts remain unchanged. Also once it hangs, it is no
longer possible for any other process to create an Outlook automation
object, until the hung Outlook process has been killed.

Anything relevant, still appreciated.


-Mark
 
Back
Top