MPS issue job003740

Titlempswin.h may change the setting of WIN32_LEAN_AND_MEAN
Assigned userGareth Rees
DescriptionIn mpswin.h [1] it says:

    #define WIN32_LEAN_AND_MEAN
    #include <windows.h>
    #undef WIN32_LEAN_AND_MEAN

But this means that if a client has defined WIN32_LEAN_AND_MEAN then including mps.h will undefine it.
AnalysisShould write:

    #ifndef WIN32_LEAN_AND_MEAN
    #define WIN32_LEAN_AND_MEAN
    #include <windows.h>
    #undef WIN32_LEAN_AND_MEAN
    #include <windows.h>

so that the setting is the same afterwards as before.
How foundinspection
Evidence[1] <>
Created byGareth Rees
Created on2014-04-06 15:06:54
Last modified byGareth Rees
Last modified on2014-04-07 18:27:58
History2014-04-06 GDR Created.


Change Effect Date User Description
185323 closed 2014-04-07 18:27:57 Gareth Rees Ensure that the WIN32_LEAN_AND_MEAN is not changed by mpswin.h.