aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--include/libssh/libssh.h12
-rw-r--r--libssh/connect.c2
2 files changed, 12 insertions, 2 deletions
diff --git a/include/libssh/libssh.h b/include/libssh/libssh.h
index 43312a6c..f0114f88 100644
--- a/include/libssh/libssh.h
+++ b/include/libssh/libssh.h
@@ -20,14 +20,24 @@ MA 02111-1307, USA. */
#ifndef _LIBSSH_H
#define _LIBSSH_H
+#ifndef _MSC_VER
#include <unistd.h>
+#include <inttypes.h>
+#else
+//visual studio hasn't inttypes.h so it doesn't know uint32_t
+typedef unsigned int uint32_t;
+typedef unsigned short uint16_t;
+typedef unsigned char uint8_t;
+typedef unsigned long long uint64_t;
+
+#endif
#ifndef _WIN32
#include <sys/select.h> /* for fd_set * */
#endif
#ifdef _WIN32
#include <winsock2.h>
#endif
-#include <inttypes.h>
+
#define LIBSSH_VERSION "libssh-0.2.1-svn"
diff --git a/libssh/connect.c b/libssh/connect.c
index 9f865bbd..504882db 100644
--- a/libssh/connect.c
+++ b/libssh/connect.c
@@ -29,7 +29,7 @@ MA 02111-1307, USA. */
#define _WIN32_WINNT 0x0501 //getaddrinfo, freeaddrinfo, getnameinfo
#include <winsock2.h>
#include <ws2tcpip.h>
-#include "wspiapi.h"
+//#include "wspiapi.h"
#else
#include <netdb.h>
#include <sys/socket.h>