From d1d9555ad05835e4d33178abd31498a4bb5de060 Mon Sep 17 00:00:00 2001 From: Micah Snyder Date: Thu, 19 Oct 2023 20:53:00 -0500 Subject: [PATCH] Windows: json-c 0.17 compatibility with ssize_t type definition (part 2) Additional changes required for Visual Studio 0.103 build. --- win32/clamav-config.h | 3 ++- win32/llvmbuild/include/llvm/System/DataTypes.h | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/win32/clamav-config.h b/win32/clamav-config.h index 00a44f92ff..03f975f8e1 100644 --- a/win32/clamav-config.h +++ b/win32/clamav-config.h @@ -573,7 +573,8 @@ /* #undef off_t */ /* Define to `int' */ -typedef int ssize_t; +#include +typedef SSIZE_T ssize_t; /* Define to the equivalent of the C99 'restrict' keyword, or to nothing if this is not supported. Do not define if restrict is diff --git a/win32/llvmbuild/include/llvm/System/DataTypes.h b/win32/llvmbuild/include/llvm/System/DataTypes.h index 17323cf911..26cdce3a75 100644 --- a/win32/llvmbuild/include/llvm/System/DataTypes.h +++ b/win32/llvmbuild/include/llvm/System/DataTypes.h @@ -109,7 +109,8 @@ typedef short int16_t; typedef unsigned short uint16_t; typedef signed char int8_t; typedef unsigned char uint8_t; -typedef signed int ssize_t; +#include +typedef SSIZE_T ssize_t; /* Certain compatibility updates to VC++ introduce the `cstdint' * header, which defines the INT*_C macros. On default installs they * are absent. */