1
0
mirror of https://git.tartarus.org/simon/putty.git synced 2025-07-09 23:33:46 -05:00

Coverity build fixes.

Like every other toolchain I've tried, my Coverity scanning build has
its share of random objections to parts of my Windows API type-
checking system. I do wonder if that bright idea was worth the hassle
- but it would probably cost all the annoyance all over again to back
out now...
This commit is contained in:
Simon Tatham
2017-06-20 19:02:48 +01:00
parent 98cbe6963b
commit 4696f4a40b
4 changed files with 26 additions and 6 deletions

View File

@ -284,10 +284,11 @@ static char *sk_handle_peer_info(Socket s)
if (!kernel32_module) {
kernel32_module = load_system32_dll("kernel32.dll");
#if (defined _MSC_VER && _MSC_VER < 1900) || defined __MINGW32__
#if (defined _MSC_VER && _MSC_VER < 1900) || defined __MINGW32__ || defined COVERITY
/* For older Visual Studio, and MinGW too (at least as of
* Ubuntu 16.04), this function isn't available in the header
* files to type-check */
* files to type-check. Ditto the toolchain I use for
* Coveritying the Windows code. */
GET_WINDOWS_FUNCTION_NO_TYPECHECK(
kernel32_module, GetNamedPipeClientProcessId);
#else