Compile without warnings with android ndk 15 beta 2

This commit is contained in:
Jeremy Lakeman 2017-06-06 15:14:17 +09:30
parent 34b6ab6ec2
commit f83b15d251
3 changed files with 3 additions and 2 deletions

View File

@ -45,6 +45,7 @@ SERVALD_LOCAL_CFLAGS = \
-DHAVE_JNI_H=1 -DHAVE_STRUCT_UCRED=1 -DHAVE_CRYPTO_SIGN_NACL_GE25519_H=1 \
-DBYTE_ORDER=_BYTE_ORDER -DHAVE_LINUX_STRUCT_UCRED -DUSE_ABSTRACT_NAMESPACE \
-DHAVE_BCOPY -DHAVE_BZERO -DHAVE_BCMP -DHAVE_NETINET_IN_H -DHAVE_LSEEK64 -DSIZEOF_OFF_T=4 \
-DHAVE_STRLCPY=1 \
-DHAVE_GETTID=1 \
-DHAVE_LINUX_IF_H -DHAVE_SYS_STAT_H -DHAVE_SYS_VFS_H -DHAVE_LINUX_NETLINK_H -DHAVE_LINUX_RTNETLINK_H \
-DSQLITE_OMIT_DATETIME_FUNCS -DSQLITE_OMIT_COMPILEOPTION_DIAGS -DSQLITE_OMIT_DEPRECATED \

View File

@ -57,7 +57,7 @@ static int rhizome_sync_with_peers(int mode, int peer_count, const struct config
const struct config_rhizome_peer *peer = peers[peer_number];
if (strcasecmp(peer->protocol, "http") != 0)
return WHYF("Unsupported Rhizome Direct protocol %s", alloca_str_toprint(peer->protocol));
strbuf h = strbuf_local_buf(state->host);
strbuf h = strbuf_local(state->host, sizeof state->host);
strbuf_puts(h, peer->host);
if (strbuf_overrun(h))
return WHYF("Rhizome Direct host name too long: %s", alloca_str_toprint(peer->host));

View File

@ -241,7 +241,7 @@ int isOverlayPacket(XPRINTF xpf, const unsigned char *packet, size_t *ofs, size_
xprintf(xpf, " OVERLAY_TYPE");
xprintf(xpf, "\n");
if (!payload_flags & 1){
if (!(payload_flags & 1)){
xprintf(xpf, "%sSender; ", indent(6));
int ret=serval_packetvisualise_renderaddress(xpf,packet,ofs);
xprintf(xpf, "\n");