1
0
mirror of https://github.com/Interlisp/maiko.git synced 2026-04-27 12:49:29 +00:00

Use getcwd() instead of getwd(). (#20)

getwd() has been deprecated for a long time and getcwd() should
be used instead.
This commit is contained in:
Bruce Mitchener
2020-12-11 00:24:21 +07:00
committed by GitHub
parent 11c083d792
commit d6d2a3371a
2 changed files with 3 additions and 7 deletions

View File

@@ -271,7 +271,6 @@ typedef unsigned long u_long;
#undef UNALIGNED_FETCH_OK
#undef HAS_GETHOSTID
#define seteuid(x) setresuid(-1, (x), -1)
#define getwd(x) getcwd((x), MAXPATHLEN)
#define getrusage(x, y)
#define getpagesize() 4096
#define USE_UTIME
@@ -308,7 +307,6 @@ typedef signed char s_char;
#undef UNALIGNED_FETCH_OK
#define MAXPATHLEN MAXNAMLEN
#define EWOULDBLOCK EAGAIN
#define getwd(x) getcwd((x), MAXPATHLEN)
/* we compile on a 386 with GCC, so can use optimizations. */
#define GCC386
#define RESWAPPEDCODESTREAM
@@ -424,7 +422,6 @@ typedef unsigned short u_short;
#define SYSVONLY 1
#define SYSVSIGNALS 1
#define NOETHER 1
#define getwd(x) getcwd((x), MAXPATHLEN)
#define USHORT unsigned
#else
#define USHORT unsigned short
@@ -453,7 +450,6 @@ typedef unsigned short u_short;
#if !defined(LINUX) && !defined(MACOSX) && !defined(FREEBSD)
/* these are in the POSIX standard */
#define getwd(x) getcwd((x), MAXPATHLEN)
#define getrusage(x, y)
#define getpagesize() 4096
#endif /* LINUX , MACOSX, FREEBSD */