summaryrefslogtreecommitdiff
path: root/standalone/android/start.c
diff options
context:
space:
mode:
authorGravatar Joey Hess <joey@kitenet.net>2013-02-24 14:10:09 -0400
committerGravatar Joey Hess <joey@kitenet.net>2013-02-24 14:31:43 -0400
commit502e6aa7f9a247dc45fb79b4e5d0a02c00601b29 (patch)
treee6d1f436eed245631ee7490f157d7badf8252e70 /standalone/android/start.c
parent4fdfc09edbf9ae7cfa1a3f1a03d6cd1d3e1599b9 (diff)
Explicitly run every command as a busybox app
Seems that CONFIG_FEATURE_SH_STANDALONE is not working.
Diffstat (limited to 'standalone/android/start.c')
-rw-r--r--standalone/android/start.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/standalone/android/start.c b/standalone/android/start.c
index 1f54ba259..95822f107 100644
--- a/standalone/android/start.c
+++ b/standalone/android/start.c
@@ -39,14 +39,13 @@ main () {
}
/* If this is the first run, set up busybox link. */
- if (stat("bin/busybox", &st_buf) != 0) {
- mkdir("bin", 0777);
- if (link("lib/lib.busybox.so", "bin/busybox") != 0) {
+ if (stat("busybox", &st_buf) != 0) {
+ if (link("lib/lib.busybox.so", "busybox") != 0) {
perror("link busybox");
exit(1);
}
}
- execl("bin/busybox", "bin/busybox", "sh", "lib/lib.runshell.so", NULL);
+ execl("./busybox", "./busybox", "sh", "lib/lib.runshell.so", NULL);
perror("error running busybox sh");
}