summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAllen Byrne <byrn@hdfgroup.org>2010-11-18 17:37:57 (GMT)
committerAllen Byrne <byrn@hdfgroup.org>2010-11-18 17:37:57 (GMT)
commit0bb0aa86e71049ae91234a91822968222b53c6cf (patch)
tree1a3e438a8168fe3aa428fbeb2bea23ece97a2e31
parent6dff34aab1da9cfade7d9876a07698ff5896d4b6 (diff)
downloadhdf5-0bb0aa86e71049ae91234a91822968222b53c6cf.zip
hdf5-0bb0aa86e71049ae91234a91822968222b53c6cf.tar.gz
hdf5-0bb0aa86e71049ae91234a91822968222b53c6cf.tar.bz2
[svn-r19823] BZ2013: Remove use of WIN32 defines. These two files were dependent on the winsock2.h header so changed WIN32 to H5_HAVE_WINSOCK_H.
Tested: windows
-rw-r--r--perform/sio_timer.h4
-rw-r--r--test/h5test.c10
2 files changed, 7 insertions, 7 deletions
diff --git a/perform/sio_timer.h b/perform/sio_timer.h
index 82f053d..1fa880d 100644
--- a/perform/sio_timer.h
+++ b/perform/sio_timer.h
@@ -26,9 +26,9 @@
# include <time.h>
#endif
-#ifdef _WIN32
+#ifdef H5_HAVE_WINSOCK_H
# include <winsock2.h>
-#endif /* _WIN32 */
+#endif /* H5_HAVE_WINSOCK_H */
/* The different types of timers we can have */
typedef enum timer_type_ {
diff --git a/test/h5test.c b/test/h5test.c
index 229efec..25b751f 100644
--- a/test/h5test.c
+++ b/test/h5test.c
@@ -27,11 +27,11 @@
#include "h5test.h"
#include "H5srcdir.h"
-#ifdef _WIN32
+#ifdef H5_HAVE_WINSOCK_H
#include <process.h>
#include <direct.h>
#include <winsock2.h>
-#endif /* _WIN32 */
+#endif /* H5_HAVE_WINSOCK_H */
/*
* Define these environment variables or constants to influence functions in
@@ -648,7 +648,7 @@ void
h5_show_hostname(void)
{
char hostname[80];
-#ifdef _WIN32
+#ifdef H5_HAVE_WINSOCK_H
WSADATA wsaData;
int err;
#endif
@@ -670,7 +670,7 @@ h5_show_hostname(void)
#else
printf("thread 0.");
#endif
-#ifdef _WIN32
+#ifdef H5_HAVE_WINSOCK_H
err = WSAStartup( MAKEWORD(2,2), &wsaData );
if ( err != 0 ) {
@@ -700,7 +700,7 @@ h5_show_hostname(void)
#else
printf(" gethostname not supported\n");
#endif
-#ifdef _WIN32
+#ifdef H5_HAVE_WINSOCK_H
WSACleanup();
#endif
}