aboutsummaryrefslogtreecommitdiff
path: root/lib/portability.c
diff options
context:
space:
mode:
authorElliott Hughes <enh@google.com>2014-11-21 21:49:05 -0600
committerElliott Hughes <enh@google.com>2014-11-21 21:49:05 -0600
commit6a29bb1ebe62ada2dad5fb50f84f23a497cd677a (patch)
treeaa85037839d28c40ea459d96edd3feb0b3e9de76 /lib/portability.c
parent3280d995b3447b7a94af006ac26d7d3656aee961 (diff)
downloadtoybox-6a29bb1ebe62ada2dad5fb50f84f23a497cd677a.tar.gz
A patch against your current ToT that builds in AOSP master.
Diffstat (limited to 'lib/portability.c')
-rw-r--r--lib/portability.c14
1 files changed, 1 insertions, 13 deletions
diff --git a/lib/portability.c b/lib/portability.c
index 17efc916..910b1ea9 100644
--- a/lib/portability.c
+++ b/lib/portability.c
@@ -5,11 +5,8 @@
*/
#include "toys.h"
-#if defined(__ANDROID__)
-#include <sys/syscall.h>
-#endif
-#if defined(__APPLE__) || defined(__ANDROID__)
+#if defined(__APPLE__)
ssize_t getdelim(char **linep, size_t *np, int delim, FILE *stream)
{
int ch;
@@ -62,16 +59,7 @@ ssize_t getline(char **linep, size_t *np, FILE *stream)
{
return getdelim(linep, np, '\n', stream);
}
-#endif
-
-#if defined(__ANDROID__)
-int sethostname(const char *name, size_t len)
-{
- return syscall(__NR_sethostname, name, len);
-}
-#endif
-#if defined(__APPLE__)
extern char **environ;
int clearenv(void)