On Mon, Aug 14, 2000 at 07:35:18AM +0000, Eric Pouech wrote:
> I'm not talking about the 16 bit init functions, but of DllEntryPoint
> exported function:
>    NE_DllProcessAttach( pTask->hModule ); called from InitTask invokes
> every DllEntryPoint of each module referenced by pTask->hModule
> so the DllEntryPoint of MMSYSTEM shall be called at that time
> but I fear the wp<don't remember the name>.dll is called first and 
> performs some calls inside MMSYSTEM which DllEntryPoint has not been
> called yet
> so, can you provide the -debugmsg +dll trace
Oh damn, you're right :)

And what you describe is exactly what happens:
The LibMain of WPIRSND.DLL is called there (upon NE_InitializeDLLs):
    /* Initialize implicitly loaded DLLs */
    ERR("init DLLs - START\n");
    NE_InitializeDLLs( pTask->hModule );
    ERR("init DLLs - END\n");
    NE_DllProcessAttach( pTask->hModule );
    ERR("attach DLLs - END\n");
and then upon NE_DllProcessAttach the DllEntryPoint of MMSYSTEM would have
been called, but this is too late, as LibMain of WPIRSND already performed
MMSYSTEM calls. Grrr.

According to this program it seems that all dlls a program/other dll depends
on have to get their DllEntryPoint called before the DllEntryPoint of the
parent program/dll.
But is this correct ??

I know that a horrible LOT of work has been put into the DLL init stuff,
so I suppose it's supposed to work...

And I don't know much about the DLL init stuff either.
(actually I never cared too much about that - until now)

Trace attached.
Sorry, it's a bit messy (yes, I know, I should clean up my TRACE messages,
but frankly spoken I really don't have too much time left).

Andreas Mohr

test.rel.gz

Reply via email to