From fbf48c65f343c2d3cce8ccd69975e9526f209fc5 Mon Sep 17 00:00:00 2001 From: Daniel Cohen Gindi Date: Sat, 20 Sep 2014 16:39:16 +0300 Subject: `strings.h` and `resolv.h` are not available on MSVC, and some POSIX functions are renamed or deprecated For all of those missing/deprecated POSIX functions, we just add a macro mapping to the _underscored version of MSVC. --- libvncclient/vncviewer.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'libvncclient/vncviewer.c') diff --git a/libvncclient/vncviewer.c b/libvncclient/vncviewer.c index 9d657ed..b12116c 100644 --- a/libvncclient/vncviewer.c +++ b/libvncclient/vncviewer.c @@ -26,6 +26,10 @@ #include #endif +#ifdef _MSC_VER +#define strdup _strdup /* Prevent POSIX deprecation warnings */ +#endif + #ifdef __STRICT_ANSI__ #define _BSD_SOURCE #define _POSIX_SOURCE -- cgit v1.2.1