Pelles C forum

Pelles C => General discussions => Topic started by: TimoVJL on April 17, 2012, 03:54:51 PM

Title: Why poide.exe polls MAPI32.dll and win.ini ?
Post by: TimoVJL on April 17, 2012, 03:54:51 PM
Have anyone idea why poide.exe polls MAPI32.dll and win.ini constantly ?
Title: Re: Why poide.exe polls MAPI32.dll and win.ini ?
Post by: CommonTater on April 17, 2012, 04:04:22 PM
Interesting.... win.ini... doesn't even exist on Windows 7 ... Mapi is part of Exchange.... 

How often is is doing this?
 
Are you certain it's POIDE... not something else?


 
Title: Re: Why poide.exe polls MAPI32.dll and win.ini ?
Post by: TimoVJL on April 17, 2012, 05:02:47 PM
Quote
How often is is doing this?
Every 200 ms.
If I remove win.ini it only check it and File -> Send... option is not active..
Title: Re: Why poide.exe polls MAPI32.dll and win.ini ?
Post by: Bitbeisser on April 17, 2012, 06:52:45 PM
Quote
How often is is doing this?
Every 200 ms.
If I remove win.ini it only check it and File -> Send... option is not active..
Of course, as you rob POIDE of the ability to know how to "Send..." as win.ini contains the link to the MAPI ("Mail API, not restricted to Exchange as mentioned before)...

Though it would seem to be a bit excessive to check this every 200msec, not quite sure how you get this number even...

Ralf
Title: Re: Why poide.exe polls MAPI32.dll and win.ini ?
Post by: TimoVJL on April 17, 2012, 07:06:23 PM
Quote
Though it would seem to be a bit excessive to check this every 200msec, not quite sure how you get this number even...
With Process Monitor.
Title: Re: Why poide.exe polls MAPI32.dll and win.ini ?
Post by: aardvajk on April 17, 2012, 07:50:59 PM
It's because GetProfileInt(L"Mapi", L"Mail", 0) and SearchPath(L"mapi32.dll") are called within the handler for WM_INITMENU. For some reason, a custom message (WM_APP) is sent everytime you left click on the main part of the window (whether it's a web browser, or code), this custom message does something which sends a WM_INITMENU and thus investgates win.ini and the path.

Even worse, the web browser window sends the custom message constantly when the mouse is within the window (you don't even have to be moving the mouse:

Open Pelles C so it shows the new start page
Open Spy++ and point it at main IDE window (the whole thing, not just the web browser bit) and put it on message view
Move the mouse onto the start page and leave it
You get a constant loop of 6 message items - the custom message, WM_INITMENU, and WM_MENUSELECT all being sent and returned from
Title: Re: Why poide.exe polls MAPI32.dll and win.ini ?
Post by: Stefan Pendl on April 17, 2012, 08:05:00 PM
Interesting.... win.ini... doesn't even exist on Windows 7
WIN.INI is virtualized on recent versions of Windows and points to the registry for compatibility with 16-bit applications.
Title: Re: Why poide.exe polls MAPI32.dll and win.ini ?
Post by: CommonTater on April 17, 2012, 08:41:48 PM
Move the mouse onto the start page and leave it
You get a constant loop of 6 message items - the custom message, WM_INITMENU, and WM_MENUSELECT all being sent and returned from

So it could be the Web Control that's doing it and not POIDE per se...?
 
Does it still do it if you close the start page?

 
Title: Re: Why poide.exe polls MAPI32.dll and win.ini ?
Post by: TimoVJL on April 17, 2012, 08:48:09 PM
Quote
Does it still do it if you close the start page?
In toolbar or project window too when mouse is above it.
Title: Re: Why poide.exe polls MAPI32.dll and win.ini ?
Post by: CommonTater on April 17, 2012, 09:52:56 PM
Quote
Does it still do it if you close the start page?
In toolbar or project window too when mouse is above it.

Bizarre...  There must be some kind of "heartbeat" running... altough I wouldn't want to guess why....