krytarowski created this revision.
krytarowski added reviewers: emaste, tfiala, clayborg.
krytarowski added subscribers: joerg, lldb-commits.
krytarowski set the repository for this revision to rL LLVM.
The getwd() and getcwd() functions conform to IEEE Std 1003.1-1990
(``POSIX.1''). The IEEE Std 1003.1-2004 (``POSIX.1'') revision marked
getwd() as legacy and recommended the use of getcwd() instead. The IEEE
Std 1003.1-2008 (``POSIX.1'') revision removed getwd() from the
specification.
The ability to specify a NULL pointer and have getcwd() allocate memory
as necessary is an extension.
The getwd() function appeared in 4.0BSD.
Repository:
rL LLVM
http://reviews.llvm.org/D15260
Files:
packages/Python/lldbsuite/test/api/multithreaded/common.h
Index: packages/Python/lldbsuite/test/api/multithreaded/common.h
===================================================================
--- packages/Python/lldbsuite/test/api/multithreaded/common.h
+++ packages/Python/lldbsuite/test/api/multithreaded/common.h
@@ -56,9 +56,9 @@
}
};
-/// Allocates a char buffer with the current working directory on Linux/Darwin
+/// Allocates a char buffer with the current working directory
inline char* get_working_dir() {
-#if defined(__APPLE__) || defined(__FreeBSD__)
+#if defined(__APPLE__) || defined(__FreeBSD__) || defined(__NetBSD__)
return getwd(0);
#else
return get_current_dir_name();
Index: packages/Python/lldbsuite/test/api/multithreaded/common.h
===================================================================
--- packages/Python/lldbsuite/test/api/multithreaded/common.h
+++ packages/Python/lldbsuite/test/api/multithreaded/common.h
@@ -56,9 +56,9 @@
}
};
-/// Allocates a char buffer with the current working directory on Linux/Darwin
+/// Allocates a char buffer with the current working directory
inline char* get_working_dir() {
-#if defined(__APPLE__) || defined(__FreeBSD__)
+#if defined(__APPLE__) || defined(__FreeBSD__) || defined(__NetBSD__)
return getwd(0);
#else
return get_current_dir_name();
_______________________________________________
lldb-commits mailing list
[email protected]
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits