diff options
author | Sascha Hauer <s.hauer@pengutronix.de> | 2020-06-11 07:35:39 +0200 |
---|---|---|
committer | Sascha Hauer <s.hauer@pengutronix.de> | 2020-06-11 07:35:39 +0200 |
commit | 1fb15fcfe9ecb079b88df7eb01f1e29144cd8f96 (patch) | |
tree | 651ae01bac7ed264934baccd0fccbfeec6905da6 /commands | |
parent | d6757bacf8180b17692682c58dd6a9938d0c3c1d (diff) | |
parent | aa2cd910c7465eaf6de04da1b4d110205ad63c77 (diff) | |
download | barebox-1fb15fcfe9ecb079b88df7eb01f1e29144cd8f96.tar.gz barebox-1fb15fcfe9ecb079b88df7eb01f1e29144cd8f96.tar.xz |
Merge branch 'for-next/sandbox-compile-test'
Diffstat (limited to 'commands')
-rw-r--r-- | commands/test.c | 1 | ||||
-rw-r--r-- | commands/tftp.c | 8 |
2 files changed, 2 insertions, 7 deletions
diff --git a/commands/test.c b/commands/test.c index 505b7c56b1..c845cec017 100644 --- a/commands/test.c +++ b/commands/test.c @@ -86,7 +86,6 @@ static int do_test(int argc, char *argv[]) if (argc < 2) return 1; - last_expr = 0; left = argc - 1; ap = argv + 1; diff --git a/commands/tftp.c b/commands/tftp.c index 1569819844..48ff00c621 100644 --- a/commands/tftp.c +++ b/commands/tftp.c @@ -20,7 +20,6 @@ static int do_tftpb(int argc, char *argv[]) { char *source, *dest, *freep; int opt; - unsigned long flags; int tftp_push = 0; int ret; IPaddr_t ip; @@ -46,13 +45,10 @@ static int do_tftpb(int argc, char *argv[]) else dest = argv[optind]; - if (tftp_push) { + if (tftp_push) dest = freep = basprintf("%s/%s", TFTP_MOUNT_PATH, dest); - flags = O_RDONLY; - } else { + else source = freep = basprintf("%s/%s", TFTP_MOUNT_PATH, source); - flags = O_WRONLY | O_CREAT; - } if (!freep) return -ENOMEM; |