apps/lib/s_socket.c: Alias getpid with _getpid for _WIN32

Reviewed-by: Shane Lontis <shane.lontis@oracle.com>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/15710)
This commit is contained in:
Richard Levitte 2021-06-11 04:55:03 +02:00
parent baa47ad3b1
commit 814b5133e9
1 changed files with 9 additions and 0 deletions

View File

@ -26,6 +26,15 @@
typedef unsigned int u_int;
#endif
#ifdef _WIN32
/*
* With MSVC, certain POSIX functions have been renamed to have an underscore
* prefix.
*/
# include <process.h>
# define getpid _getpid
#endif
#ifndef OPENSSL_NO_SOCK
# include "apps.h"