util: Remove include of windows.h in memstream.h

Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18425>
This commit is contained in:
Yonggang Luo 2022-09-03 17:21:58 +08:00 committed by Marge Bot
parent c2a486120b
commit c30d63a53d
2 changed files with 12 additions and 3 deletions

View file

@ -27,6 +27,10 @@
#include <stdlib.h>
#ifdef _WIN32
#include <windows.h>
#endif
bool
u_memstream_open(struct u_memstream *mem, char **bufp, size_t *sizep)
{

View file

@ -30,8 +30,13 @@
#include <stdbool.h>
#include <stdio.h>
#ifdef _WIN32
#include <windows.h>
#include <limits.h> /* PATH_MAX */
#ifdef _MSC_VER
#include <stdlib.h>
#ifndef PATH_MAX
#define PATH_MAX _MAX_PATH /* Equivalent to MAX_PATH from minwindef.h */
#endif
#endif
#ifdef __cplusplus
@ -44,7 +49,7 @@ struct u_memstream
#ifdef _WIN32
char **bufp;
size_t *sizep;
char temp[MAX_PATH];
char temp[PATH_MAX];
#endif
};