From 349e8aede8584820ddbe6bb61bb601151f17207b Mon Sep 17 00:00:00 2001 From: Bruno Lopes Date: Sat, 29 Nov 2025 21:07:22 -0300 Subject: [PATCH] plug-ins: More Windows IO fixes, now at imagemap Following 8748b8bb --- plug-ins/imagemap/imap_cern_lex.c | 5 ++++- plug-ins/imagemap/imap_csim_lex.c | 5 ++++- plug-ins/imagemap/imap_ncsa_lex.c | 5 ++++- 3 files changed, 12 insertions(+), 3 deletions(-) diff --git a/plug-ins/imagemap/imap_cern_lex.c b/plug-ins/imagemap/imap_cern_lex.c index eb761d2b89..b5d595d05a 100644 --- a/plug-ins/imagemap/imap_cern_lex.c +++ b/plug-ins/imagemap/imap_cern_lex.c @@ -618,13 +618,16 @@ char *cern_text; #define INITIAL 0 #define comment 1 -#ifndef YY_NO_UNISTD_H +#if !defined(YY_NO_UNISTD_H) && defined(HAVE_UNISTD_H) /* Special case for "unistd.h", since it is non-ANSI. We include it way * down here because we want the user's section 1 to have been scanned first. * The user has a chance to override it with an option. */ #include #endif +#ifdef _WIN32 +#include +#endif #ifndef YY_EXTRA_TYPE #define YY_EXTRA_TYPE void * diff --git a/plug-ins/imagemap/imap_csim_lex.c b/plug-ins/imagemap/imap_csim_lex.c index 178d49fb43..760244c5f9 100644 --- a/plug-ins/imagemap/imap_csim_lex.c +++ b/plug-ins/imagemap/imap_csim_lex.c @@ -643,13 +643,16 @@ char *csim_text; #define quoted_string 1 #define comment 2 -#ifndef YY_NO_UNISTD_H +#if !defined(YY_NO_UNISTD_H) && defined(HAVE_UNISTD_H) /* Special case for "unistd.h", since it is non-ANSI. We include it way * down here because we want the user's section 1 to have been scanned first. * The user has a chance to override it with an option. */ #include #endif +#ifdef _WIN32 +#include +#endif #ifndef YY_EXTRA_TYPE #define YY_EXTRA_TYPE void * diff --git a/plug-ins/imagemap/imap_ncsa_lex.c b/plug-ins/imagemap/imap_ncsa_lex.c index 56f2fe1966..87acdc3807 100644 --- a/plug-ins/imagemap/imap_ncsa_lex.c +++ b/plug-ins/imagemap/imap_ncsa_lex.c @@ -583,13 +583,16 @@ char *ncsa_text; #define imap_link 1 #define comment 2 -#ifndef YY_NO_UNISTD_H +#if !defined(YY_NO_UNISTD_H) && defined(HAVE_UNISTD_H) /* Special case for "unistd.h", since it is non-ANSI. We include it way * down here because we want the user's section 1 to have been scanned first. * The user has a chance to override it with an option. */ #include #endif +#ifdef _WIN32 +#include +#endif #ifndef YY_EXTRA_TYPE #define YY_EXTRA_TYPE void *