diff options
| author | Sean Hall <r.sean.hall@gmail.com> | 2021-02-07 17:56:58 -0600 |
|---|---|---|
| committer | Sean Hall <r.sean.hall@gmail.com> | 2021-02-07 18:54:33 -0600 |
| commit | bee6a20d1c7d807b5023d932ae179db1bc9a0f80 (patch) | |
| tree | 855c28ed77f81d8212d1a9ecf67253c97190935a /src/dutil/osutil.cpp | |
| parent | 69567aaa95f41812a49afa7454b69a3d79c5010d (diff) | |
| download | wix-bee6a20d1c7d807b5023d932ae179db1bc9a0f80.tar.gz wix-bee6a20d1c7d807b5023d932ae179db1bc9a0f80.tar.bz2 wix-bee6a20d1c7d807b5023d932ae179db1bc9a0f80.zip | |
Ignore enum CA warnings and scope the osutil deprecation suppression.
Also, fix project reference so the .vcx project system understands it.
Diffstat (limited to 'src/dutil/osutil.cpp')
| -rw-r--r-- | src/dutil/osutil.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/dutil/osutil.cpp b/src/dutil/osutil.cpp index 38b32eb3..8834cd30 100644 --- a/src/dutil/osutil.cpp +++ b/src/dutil/osutil.cpp | |||
| @@ -22,7 +22,14 @@ extern "C" void DAPI OsGetVersion( | |||
| 22 | if (OS_VERSION_UNKNOWN == vOsVersion) | 22 | if (OS_VERSION_UNKNOWN == vOsVersion) |
| 23 | { | 23 | { |
| 24 | ovi.dwOSVersionInfoSize = sizeof(OSVERSIONINFOEXW); | 24 | ovi.dwOSVersionInfoSize = sizeof(OSVERSIONINFOEXW); |
| 25 | |||
| 26 | #pragma warning (push) | ||
| 27 | #pragma warning(suppress: 4996) // deprecated | ||
| 28 | #pragma warning (push) | ||
| 29 | #pragma warning(suppress: 28159)// deprecated, use other function instead | ||
| 25 | ::GetVersionExW(reinterpret_cast<OSVERSIONINFOW*>(&ovi)); // only fails if version info size is set incorrectly. | 30 | ::GetVersionExW(reinterpret_cast<OSVERSIONINFOW*>(&ovi)); // only fails if version info size is set incorrectly. |
| 31 | #pragma warning (pop) | ||
| 32 | #pragma warning (pop) | ||
| 26 | 33 | ||
| 27 | vdwOsServicePack = static_cast<DWORD>(ovi.wServicePackMajor) << 16 | ovi.wServicePackMinor; | 34 | vdwOsServicePack = static_cast<DWORD>(ovi.wServicePackMajor) << 16 | ovi.wServicePackMinor; |
| 28 | if (4 == ovi.dwMajorVersion) | 35 | if (4 == ovi.dwMajorVersion) |
