//===-- GDBRemoteTestUtils.cpp ----------------------------------*- C++ -*-===//
//
//                     The LLVM Compiler Infrastructure
//
// This file is distributed under the University of Illinois Open Source
// License. See LICENSE.TXT for details.
//
//===----------------------------------------------------------------------===//

#include "GDBRemoteTestUtils.h"

#if defined(_MSC_VER)
#include "lldb/Host/windows/windows.h"
#include <WinSock2.h>
#endif

namespace lldb_private {
namespace process_gdb_remote {

void GDBRemoteTest::SetUpTestCase() {
#if defined(_MSC_VER)
  WSADATA data;
  ::WSAStartup(MAKEWORD(2, 2), &data);
#endif
}

void GDBRemoteTest::TearDownTestCase() {
#if defined(_MSC_VER)
  ::WSACleanup();
#endif
}

} // namespace process_gdb_remote
} // namespace lldb_private

//===-- GDBRemoteTestUtils.cpp ----------------------------------*- C++ -*-===//
//
//                     The LLVM Compiler Infrastructure
//
// This file is distributed under the University of Illinois Open Source
// License. See LICENSE.TXT for details.
//
//===----------------------------------------------------------------------===//

#include "GDBRemoteTestUtils.h"

namespace lldb_private {
namespace process_gdb_remote {

void GDBRemoteTest::SetUpTestCase() {
#if defined(_MSC_VER)
  WSADATA data;
  ::WSAStartup(MAKEWORD(2, 2), &data);
#endif
}

void GDBRemoteTest::TearDownTestCase() {
#if defined(_MSC_VER)
  ::WSACleanup();
#endif
}

} // namespace process_gdb_remote
} // namespace lldb_private

--- 
+++ 
@@ -8,6 +8,11 @@
 //===----------------------------------------------------------------------===//
 
 #include "GDBRemoteTestUtils.h"
+
+#if defined(_MSC_VER)
+#include "lldb/Host/windows/windows.h"
+#include <WinSock2.h>
+#endif
 
 namespace lldb_private {
 namespace process_gdb_remote {
Fix compilation failure in unit tests on Windows.

git-svn-id: 4c4cc70b1ef44ba2b7963015e681894188cea27e@346999 91177308-0d34-0410-b5e6-96231b3b80d8
