aboutsummaryrefslogtreecommitdiff
path: root/sysdeps/posix
diff options
context:
space:
mode:
Diffstat (limited to 'sysdeps/posix')
-rw-r--r--sysdeps/posix/getcwd.c9
-rw-r--r--sysdeps/posix/system.c1
2 files changed, 8 insertions, 2 deletions
diff --git a/sysdeps/posix/getcwd.c b/sysdeps/posix/getcwd.c
index 01f86ef..2ae3c1e 100644
--- a/sysdeps/posix/getcwd.c
+++ b/sysdeps/posix/getcwd.c
@@ -135,6 +135,11 @@ extern void free ();
# define memmove memcpy
#endif /* Not ANSI_STRING. */
+#ifdef _LIBC
+# define mempcpy __mempcpy
+# define HAVE_MEMPCPY 1
+#endif
+
#if !defined __alloca && !defined __GNU_LIBRARY__
# ifdef __GNUC__
@@ -277,10 +282,10 @@ __getcwd (buf, size)
dotp = &new[dotsize];
}
#ifdef HAVE_MEMPCPY
- *((char *) mempcpy (dotp, new, dotsize)) = '\0';
+ *((char *) mempcpy ((char *) dotp, new, dotsize)) = '\0';
dotsize *= 2;
#else
- memcpy (dotp, new, dotsize);
+ memcpy ((char *) dotp, new, dotsize);
dotsize *= 2;
new[dotsize] = '\0';
#endif
diff --git a/sysdeps/posix/system.c b/sysdeps/posix/system.c
index 2b8f9cb..1111646 100644
--- a/sysdeps/posix/system.c
+++ b/sysdeps/posix/system.c
@@ -44,6 +44,7 @@ __libc_system (const char *line)
#endif
if (line == NULL)
+ /* This signals that we have a command processor available. */
return 1;
sa.sa_handler = SIG_IGN;