From e043fcec4663b8d3ae239deda34610f38680368a Mon Sep 17 00:00:00 2001 From: v1gnesh Date: Mon, 5 Jun 2023 20:10:05 +0530 Subject: [PATCH] Add support for zOS Signed-off-by: v1gnesh --- httplib.h | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/httplib.h b/httplib.h index ae32939781..0398253dbf 100644 --- a/httplib.h +++ b/httplib.h @@ -172,9 +172,15 @@ using socket_t = SOCKET; #else // not _WIN32 #include -#ifndef _AIX +#if !defined(_AIX) && !defined(__MVS__) #include #endif +#ifdef __MVS__ +#include +#ifndef NI_MAXHOST +#define NI_MAXHOST 1025 +#endif +#endif #include #include #include @@ -2805,7 +2811,7 @@ inline bool bind_ip_address(socket_t sock, const std::string &host) { return ret; } -#if !defined _WIN32 && !defined ANDROID && !defined _AIX +#if !defined _WIN32 && !defined ANDROID && !defined _AIX && !defined __MVS__ #define USE_IF2IP #endif