[Lldb-commits] [PATCH] Make print_cwd buildable on Windows

Adrian McCarthy amccarth at google.com
Fri Feb 27 15:50:49 PST 2015


Makes sense.  Changed to _MSC_VER.  Thanks.


http://reviews.llvm.org/D7962

Files:
  test/functionalities/process_launch/print_cwd.cpp

Index: test/functionalities/process_launch/print_cwd.cpp
===================================================================
--- test/functionalities/process_launch/print_cwd.cpp
+++ test/functionalities/process_launch/print_cwd.cpp
@@ -1,5 +1,13 @@
 #include <stdio.h>
+
+#ifdef _MSC_VER
+#define _CRT_NONSTDC_NO_WARNINGS
+#include <direct.h>
+#undef getcwd
+#define getcwd(buffer, length) _getcwd(buffer, length)
+#else
 #include <unistd.h>
+#endif
 
 int
 main (int argc, char **argv)

EMAIL PREFERENCES
  http://reviews.llvm.org/settings/panel/emailpreferences/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D7962.20909.patch
Type: text/x-patch
Size: 488 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20150227/35d72973/attachment.bin>


More information about the lldb-commits mailing list