[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
getcwd on MSVC
From: |
Bruno Haible |
Subject: |
getcwd on MSVC |
Date: |
Fri, 23 Sep 2011 12:06:18 +0200 |
User-agent: |
KMail/1.13.6 (Linux/2.6.37.6-0.5-desktop; KDE/4.6.0; x86_64; ; ) |
A simple doc tweak:
2011-09-23 Bruno Haible <address@hidden>
getcwd: Tweak for MSVC 9.
* lib/unistd.in.h: Update comments.
* doc/posix-functions/getcwd.texi: Mention problem on MSVC 9.
--- doc/posix-functions/getcwd.texi.orig Fri Sep 23 12:03:54 2011
+++ doc/posix-functions/getcwd.texi Fri Sep 23 12:03:01 2011
@@ -10,6 +10,10 @@
@code{getcwd-lgpl}:
@itemize
@item
+This function is declared in different header files (namely, @code{<io.h>} or
address@hidden<direct.h>}) on some platforms:
+mingw, MSVC 9.
address@hidden
On glibc platforms, @code{getcwd (NULL, n)} allocates memory for the result.
On some other platforms, this call is not allowed.
@item
--- lib/unistd.in.h.orig Fri Sep 23 12:03:54 2011
+++ lib/unistd.in.h Fri Sep 23 12:03:17 2011
@@ -83,11 +83,12 @@
# include <stdlib.h>
#endif
-/* mingw declares getcwd in <io.h>, not in <unistd.h>. */
+/* Native Windows platforms declare getcwd in
+ <io.h> and/or <direct.h>, not in <unistd.h>. */
#if ((@GNULIB_GETCWD@ || defined GNULIB_POSIXCHECK) \
&& ((defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__))
# include <io.h> /* mingw32, mingw64 */
-# include <direct.h> /* mingw64 */
+# include <direct.h> /* mingw64, MSVC 9 */
#endif
/* AIX and OSF/1 5.1 declare getdomainname in <netdb.h>, not in <unistd.h>.
--
In memoriam Ghazala Khan <http://en.wikipedia.org/wiki/Ghazala_Khan>
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- getcwd on MSVC,
Bruno Haible <=