Tweaks to make building with Android NDK's llvm happier.
This commit is contained in:
parent
ef3044114a
commit
288321ac86
@ -55,7 +55,7 @@ static inline char *lsm_name(void)
|
||||
static inline char *lsm_context(void)
|
||||
{
|
||||
int ok = 0;
|
||||
char *result;
|
||||
char *result = 0;
|
||||
|
||||
if (CFG_TOYBOX_SMACK) ok = smack_new_label_from_self(&result) > 0;
|
||||
else ok = getcon(&result) == 0;
|
||||
|
@ -256,3 +256,11 @@ extern CODE prioritynames[], facilitynames[];
|
||||
#include <sys/random.h>
|
||||
#endif
|
||||
void xgetrandom(void *buf, unsigned len, unsigned flags);
|
||||
|
||||
// android NDK doesn't have confstr
|
||||
#ifndef _CS_PATH
|
||||
#define _CS_PATH 0
|
||||
#define _CS_V7_ENV 1
|
||||
#include <string.h>
|
||||
static inline void confstr(int a, char *b, int c) {strcpy(b, a ? "POSIXLY_CORRECT=1" : "/bin:/usr/bin");}
|
||||
#endif
|
||||
|
@ -93,7 +93,7 @@ static int ftp_line(char *cmd, char *arg, int must)
|
||||
void ftpget_main(void)
|
||||
{
|
||||
struct sockaddr_in6 si6;
|
||||
int rc, ii = 1, port;
|
||||
int rc, ii = 1, port = 0;
|
||||
socklen_t sl = sizeof(si6);
|
||||
char *s, *remote = toys.optargs[2];
|
||||
unsigned long long lenl = 0, lenr;
|
||||
|
Loading…
Reference in New Issue
Block a user