From: Angelo Mantellini Date: Sat, 16 Mar 2019 10:14:46 +0000 (+0100) Subject: the definition of read is not enabled when c++ compiler is available (only windows) X-Git-Url: https://gerrit.fd.io/r/gitweb?a=commitdiff_plain;h=refs%2Fchanges%2F47%2F18347%2F1;p=cicn.git the definition of read is not enabled when c++ compiler is available (only windows) Change-Id: I1dc33627a91a2a99a40d6a9f3714911a6e172f78 Signed-off-by: Angelo Mantellini --- diff --git a/libparc/parc/windows/parc_Utils.h b/libparc/parc/windows/parc_Utils.h index 85cdc94e..25b012a2 100644 --- a/libparc/parc/windows/parc_Utils.h +++ b/libparc/parc/windows/parc_Utils.h @@ -113,6 +113,10 @@ int dprintf(int fd, char *fmt, ...); #ifndef __cplusplus +#ifndef read +#define read _read +#endif + #ifndef close #define close _close #endif @@ -131,10 +135,6 @@ int dprintf(int fd, char *fmt, ...); #define unlink _unlink #endif -#ifndef read -#define read _read -#endif - #ifndef strcasecmp #define strncasecmp _strnicmp #endif